09-13-2011 03:53 AM
I'm using a .NET messagebox object and it loads very slow. I wait 30 seconds before it pop-up? Does LV need to load the full framework in memory before running any .NET code?
Solved! Go to Solution.
09-13-2011 09:45 AM
There is no such thing as loading the full framework into memory. Please post the code. Also indicate which version of .NET you are trying to use.
09-13-2011 12:34 PM
🙂 That's nice to hear. The code is just a show() invoke node from a messagebox object.
The strange thing is the first time it takes 30 seconds to show the messagebox, the times after it's there in a flash??
The code is running on an intel atom 2GHz-2Gb RAM with LV DE 2010 installed.
09-13-2011 01:24 PM
An Atom? Is this a netbook? Aren't those things notoriously slow? Regardless, which .NET version are you using?
I just had a quick check on a LV2010 installation inside a virtual machine, and the MessageBox.Show() came up real quick. Even the first time.
09-13-2011 01:46 PM
All-in-one from Assus. It's a slow machine indeed. On my i7 it's very quick as well.
The strange thing is that ones it's loaded(it looks like it's loading something or configuring) it behaves normal. Isn't there any optimalisation?
I must check the .NET version.
09-14-2011 01:07 AM
NI advice to put the assemblies into the project directory. I only find stdole.dll in the .NET folder. I copied this .dll to my project folder and when I open the vi when LV is still not running it seem to behave normal. It only takes a long time for the vi to start. When I remove the .NET it start fast.
When LV is already open and I load then the vi, the .NET is still slow. Also in the RT engine it's slow.
09-14-2011 02:13 AM
Upgrade to .NET framework 4 was the solution.
12-14-2011 10:16 AM
Could you tell me how can you call show() method for a messagebox object, beacuse I can not use MessageBox constructor in LV (No public constructor)
Could you help me? thanks in advance!
12-14-2011 10:18 AM
@Durnek wrote:
Could you tell me how can you call show() method for a messagebox object, beacuse I can not use MessageBox constructor in LV (No public constructor)
Could you help me? thanks in advance!
You should start a new tread for this question.
12-14-2011 10:53 AM
show() is just a method that takes a string as argument. http://msdn.microsoft.com/en-us/library/519bytz3.aspx
I don't think u need to use a constructor for message box. Just use the invoke functionblock and select the .NET messagebox class. After u select the show() method.