Hi Team,

I need a kind help for the below scenarios .

1) I have developed a OPC DA client with all necessary softwares installed on my PC .
2) Below is the code when i run on PYCHARM , its runs successfully as shown below in the below snap with WHITE Editor and EXE OPC DA client in BLACK SCREEN..

4) But when develop the same client as an standalone EXE file -build using PyInstaller . the apps gives the below errors as :
Outer Loop Minute Change
Postgre SQL Connection Opened
['Simulation Items', 'Configured Aliases']
pythoncom error: Failed to setup call into Python gateway

ModuleNotFoundError: No module named 'win32timezone'

Python Code :

        opc = OpenOPC.client()
        ser = opc.servers()
        var = opc.connect('Matrikon.OPC.Simulation.1', 'localhost')
        print(opc.list())
        opc_value_per_tag = opc.read('Random.Int1')[0]
        print(opc_value_per_tag)

Pls suggest and help colleagues as i have bbeen struggling since 10-15 days , but this platform is the last hope where i can get help from you all.

Thanks

Rajnish Vishwakarma

Mumbai , Maharashtra , India

 

Last edit: Rajnish Vishwakarma 2021-12-25