LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

MessagePopup() shows "Invalid Double Number" in place of "OK" on OK button

I was modifying an existing program that was previously working. Now, when compiled & run on the test system (win98 2e), the MessagePopup() window shows "Invalid Double Number" on the OK button instead of "OK". When the button is pressed, the program crashes. I cannot reproduce this symptom on my machine (running Me), but can reproduce it on a Win2000 machine. The symptom does not appear when run from the development system, even if debugging is off.

The compiler is CVI 5.0.1. It looks like a memory corruption problem to me, but can I use this symptom to help track it down? Any ideas?

Thanks for your help!
0 Kudos
Message 1 of 7
(3,909 Views)
Hello Gary,
This certainly is very strange! What has changed in your code since you started modifying it? What is the nature of the program? I assume that it builds correctly without any warnings or errors. It is very strange that it would work on an ME machine, but fail on a 2k machine.

Best Regards,
Aaron Kobayashi
Application Engineer
National Instruments
0 Kudos
Message 2 of 7
(3,909 Views)
Here's some more info:

1) The program is an automated test system utilizing GPIB and PC based test equipment. It compiles clean, no errors or warnings.

2) A Win98 system I have behaves like the Me system - "OK" is OK and it gets to the entry panel. The Win2K system gives the invalid # error, & produces the panel. Only the win98 system in the test system crashes, possibly due to the fact that it has all the equipment & drivers installed. I do not have a full set of GPIB equipment onsite.

3)I have attached a code snippet with the areas of interest. The MessagePopup() function displays the invalid # error, yet it is *before* the Entry() function, where I have been working.

However, here's another bit of info that makes me suspect that
the 2 problems may not be related: I ran the NI GPIB analyzer utility for NT (ver 2.0) & it produced a warning box, stating that Win2K wasn't fully supported yet, but some featues could be used, etc. On the sole button of this window appears... "Invalid double number"! Since I did not compile that program (it's from NI), I can only assume that this symptom is a function of CVI or the compiler used to create CVI, and not of my code. What do you think?

Based on this, here's my plan:
1) I removed the MessagePopup() window to see if the program crash disappears. I am waiting for feedback.
2) I'll be walking through the code looking for the usual C errors & hazards.

Thank you for your assistance!
0 Kudos
Message 3 of 7
(3,908 Views)
Hi Gary,
Well this is very interesting. One thing I can tell you is if you head over to http://ni.com/support/gpib/versions.htm, it will display a table showing the cards and their supported versions. 2.0 is not supported for all cards. Possibly your card needs to use an older version? This could be the problem!

Aaron Kobayashi
Application Engineer
National Instruments
0 Kudos
Message 4 of 7
(3,908 Views)
Here's an update:

1) The crash was caused by one of the UIR files. I had changed the file, but we were running it with the old version of the file. Once we put in the updated UIR file, it ran fine.

2) The "Invalid Double Number" phenomenon still haunts us. Since it existed in the old versions of our software, as well as in NI's own software, I am going to assume that it is eitehr a bug in CVI, the compiler used to generate CVI or Windows. Since it appears to do no harm, we'll classify it as a "cosmetic" bug & leave it at that.

That solves my problem. Thanks for the help!
0 Kudos
Message 5 of 7
(3,908 Views)
Hi Gary,
Great! Glad to hear that the problem was solved, and thank you for posting your questions to the developer exchange! Good luck with your application.

Best Regards,
Aaron Kobayashi
Application Engineer
National Instruments
0 Kudos
Message 6 of 7
(3,908 Views)
----------------------------------------
Dear Mr. Kobayashi,
It has been a long time since I have written to u about Labview. I would
like to ask you a favor to help look for the *.vi file that i used to send
to you about 2 years ago when I had a question about Labview. The title of e-mail should be
(Reference#9361-PX7843) Automated Triggering using computer clock. I am now working on a different subject now but
another student is interested and currently working on that same project that I used to work on. I don't have the VI file that i used to write anymore because it was in the old computer that has been now replaced with a new one. If you happen to have that file available, could u please send it to me. Thank you so very much for your help.
Sincerely,
_Wonsiri
> Hi Wonsiri,
>
> Hey no problem.  Hope your project works out well!
>
> I had a chance to run that program I sent you and I think my logic was
> backward for the case statement.  Just so you know.  But the idea is
still
> relevant!
>
>
>
> Best Regards,
>
> Aaron Kobayashi
> Applications Engineer
> National Instruments
> http://www.ni.com/support
>
>
> Dear Mr. Kobayashi,
>
> Thank you very much for your kindness. I appreciate your help. I must
admit
> that I
> haven't looked at it in detail. However, I am sure that it must be the
> answer that I
> have been looking forward to.
>
> Wish you the best,
>
> -Wonsiri
 
> >
> > Hi Wonsiri,
> >
> > I was unable to load your vi completely because I did not have the
> > driver
> > installed, but I was able to get the idea.
> >
> > Normally we don't write code, but I decided it would be easy to create
> > something to show you how you could do it.  I have not tested that
> > attached
> > program so you will have to play with it if you want to get it to
> > work,,
> > but it should give you an idea of how you might go about creating a
> > comma
> > separated text file you could then import into excel.  Hope this helps
> > you
> > out Wonsiri!
> > Best Regards,
> >
> > Aaron Kobayashi
> > Applications Engineer
> > National Instruments
> > http://www.ni.com/support
> >
> >
>
----------------


0 Kudos
Message 7 of 7
(3,847 Views)