11-29-2015 10:53 PM
I am trying to open the vi through labview executable in python code
Have tried this but failed
import win32com.client
labview = win32com.client.Dispatch("Labview.Application")
VI = labview.getvireference(r'C:\labview\myexe\my.vi')
11-30-2015 01:55 AM - edited 11-30-2015 01:56 AM
@jigneshmehta wrote:
I am trying to open the vi through labview executable in python code
Have tried this but failed
import win32com.client
labview = win32com.client.Dispatch("Labview.Application")
VI = labview.getvireference(r'C:\labview\myexe\my.vi')
Have you configured your EXE file to allow remote access to this VI? The LabVIEW VI server does only allow external applications to access VIs that have been explicitedly configured to be accessible. That are the same settings as used in LabVIEW itself. So the easiest is to go into your LabVIEW configuration settings dialog and configure the VI server to allow access through ActiveX and then add the name of the VIs you want to be accessible to the exported VI list. Then look in your LabVIEW.ini file for these settings and copy them over to your <myapp>.ini file.
11-30-2015 04:40 AM
I have even tried but the python code is not able to find the VI path
11-30-2015 06:57 AM
I think you shouldn't try the entire path but simply the VI name only or maybe if you have a more complex application, the relative path inside the executeable.