"Error: Expected Name of Target Window"

Hi, I keep getting an error that says "Igor pro wants you know... multipeak fit failed: Expected Name of Target Window." I know the error happens on the FuncFit line, but not sure how to fix it. I can see the live updates to the graph of the funcfit working, but does not stay or outputs the results. I have attached the code below. It is the original funcfit line in the multipeak fit code. I am trying to make the code an automated system without having to use the panels. Thanks in advance for any help provided!

Welcome to the forum. But first a note that this sub-forum is about 'Wavemetrics.com', i.e., topics regarding the website, not about Igor Pro. It might be better if you could post in the 'General' sub-forum. Unfortunately, your post is omitting a bunch of crucial information, so it is almost impossible to help you at the moment.

As a start, please let us know which Igor version with which OS you are using? Multipeak Fit undergoes constant updates and bug fixes, so it would not be useful to discuss an outdated version. It seems that you also have worked in the code here. I would think it would be better to adapt your automated process to the existing Multipeak Fit, instead of trying to rewrite things in there. It is very likely that you are simply providing the wrong input to AutoMPFit(). Could you post an example experiment of what you are trying to do with some explanation (and please not here but in the General forum). Again, it should not be the goal to work inside the MPF code yourself. If you have found a bug and can explain how to trigger it, then the WM team will quickly fix it.

 

@chozo: Thanks for pointing out that this was in the wrong forum. I've moved it to the right one.