Read Variable using Excel

Hi ,

I'm encountering an issue with Excel with Macro (.xlsm) file which is used to read values from Citect and log it in an excel sheet.

This function is working fine in older version like Citect 7.3 but after upgrade the Citect 7.3 to Plant SCADA 2020R2, the same excel file cannot read values as it can't start the Citect.exe application.

Can anyone advise on this issue?

  • From at least version 6.x and higher, Citect / Plant SCADA is started by running Citect32.exe, not Citect.exe.
    Since you were having no problems in v7.3 I'm not sure where this error message is originating from.

    What mechanism is your macro using to connect to Citect? ODBC, CtApi, or something else?

  • Since it worked for you in 7.3, I’m thinking that you’re perhaps using own app called ‘Citect.exe’ that use ctapi as ‘gateway’ between Citect runtime and excel? If that’s the case perhaps yore missed to copy that app to the same location that excel tries to start it from on your new installation?

  • Sounds like your spreadsheet is using DDE to connect to Citect. In your cells, you should have a formula like: =Citect|Variable!'ProcessVariable1' 

    I believe if the Citect runtime isn't running, Excel would (incorrectly) assume 'Citect' is the application name it needs to run to connect to the DDE server. I believe the DDE topic name 'Citect' was created back when Citect was a 16-bit app and the executable was citect.exe. In Citect 2018R2 and later you have to set the Citect.ini parameter [DDE]Enable=1 because the DDE server is now disabled by default for better security.