LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Excel ActiveX slow when not connected to internet

Using LabVIEW 8.5
I hope someone has some insight into this problem because I'm lost. I have a program that communicates with a VXI instrument using a direct connection (crossover cable). I have a subVI in the program that takes data already in the program and writes it to an exisitng Excel workbook using ActiveX. When I run this subVI by itself when I have internet access (DHCP enabled), the subVI takes <2 sec to complete. However, when I am conencted to the instrument using a crossover cable, the subVI occassionally (about 1 out of 3 runs) takes >13 sec to complete. As a test, I connected back to my normal network but kept the manual TCP/IP settings (so Local Area Connection shows a network connection but I can't access the internet). I got the same result, with the subVI taking >13 sec to complete at time. Can anyone explain this behavior? Any remedies? I assume Excel or ActiveX is trying to access the internet, but that doesn't make a lot of sense.
 
Perhaps a related issue is when I don't have internet conection LabVIEW has problems updating the Block Diagram (i.e. a right click on a wire takes several seconds to bring up the shortcut menu and causes LabVIEW to freeze). Any rememdy for this? I don't know if it is completely related to the issue above, because I created an installer of the subVI and it still exhibits the same behavior (unless maybe its a LabVIEW Run TIme issue?)
 
I've attached the necessary VI's. To test you'll need to create some Excel workbook and then change the File Path control in the subVI. Also change your TCP/IP settings to something random (I use 192.168.0.2, sub 255.255.255.0, gtwy 192.168.1.1, dns 192.168.1.2, alt dns 192.168.1.3). Any suggestions welcome, or even verification of the behavior I've described.
 
Thanks
Michael
Download All
0 Kudos
Message 1 of 9
(3,877 Views)

I narrowed it down to Automation Open, it takes a long time to process when there is no internet connection (but Local Area Connection is connected). The attached VI illustrates. From my testing, this is not a problem if no network is detected or Excel is open. Any ideas?

Michael

0 Kudos
Message 2 of 9
(3,862 Views)
Hi Michael,
 
Thank you for contacting National Instruments.  I have taken a look at the files and the circumstances that you have posted here, but I have not been able to replicate the same results.  In looking through some resources available online, it is very possible that the ActiveX call could require some form of communication with the internet.  ActiveX is commonly used for making a control work well in the Internet environment, and were written to work with Internet Explorer.  Is it possible to isolate the problem to the ActiveX call by using another application other than Microsoft Excel?  Is this application intended to be run in an environment without an internet connection?  What operating system are you using to run this application?
 
Regards,
 
Jason W.
National Instruments
Applications Engineer
0 Kudos
Message 3 of 9
(3,828 Views)

Thanks for the response. I tried several different ActiveX applications like you suggested including: Microsoft Word 12.0 Objects Library Version 2.4,  Microsoft Internet Controls Version 1.1 Internet Explorer IWebBroswerApp, Microsoft Outlook 11.0 Object Library Version 9.2 Application, etc. The only one I could get to exhibit the same behavior as the Excel app was Microsoft Visio 11.0 Type Library Versionn 4.b, and thats because Visio itself opens when I run the Automation Open then Close.

I then tried opening both Excel and Visio seperately by double clicking their link instead of using LabVIEW and ActiveX with the changed TCP/IP settings , and the same behavior was shown; occassinally it would take about 12 sec to open. So it must not be an ActiveX issue but something with Excel and Visio and my computer (since you didn't see the same behavior on yours). I guess I'll have to go searching the web for an answer...

For completeness and to answer your questions, the environment does not have an internet connection (see first post, network created by a computer with a crossover cable to a VXI-11 instrument). Using Windows XP and Office 2003

Michael

0 Kudos
Message 4 of 9
(3,808 Views)
Hi,
One thing you might try to isolate the problem would be to not specify a DNS server.  Since your environment is not connected to the internet it is not necessary.  It might be that specifing a DNS nerver causes Windows to search for one slowing down your application.
Eric A.
National Instruments
Distributed I/O Product Support Engineer
0 Kudos
Message 5 of 9
(3,790 Views)

Thanks for the DNS suggestion, I followed it and the problem improved; when Excel takes awhile to open its only ~5 secs instead of 12 secs. I still haven't figured out why this is; I may just have to live with it. 

Michael

0 Kudos
Message 6 of 9
(3,733 Views)

I see this post is very old, but any solution yet.

 

I HAVE THE EXACT OPPOSITE PROBLEM.  SLOW when connected to internet via LAN at work.  Excel read takes 2 seconds versus .2 when connected.

Shannon F
0 Kudos
Message 7 of 9
(3,091 Views)

I see this post is very old, but any solution yet.

 

I HAVE THE EXACT OPPOSITE PROBLEM.  SLOW when connected to internet via LAN at work.  Excel read takes 2 seconds versus .2 when connected.

Shannon F
0 Kudos
Message 8 of 9
(3,090 Views)

Hi Shannon,

 

I'm sorry to hear you are having this issue, could you give us a little more information?

 

Are you getting this slow read every time when connected, or is it intermittent?

Do you get this behavior with any other ActiveX calls?

 

Regards,

Luke B.

0 Kudos
Message 9 of 9
(3,067 Views)