CODESYS - the IEC 61131-3 automation software
https://forum.codesys.com/

EXP file not being imported.
https://forum.codesys.com/viewtopic.php?f=1&t=8813
Page 1 of 1

Author:  PJE [ Tue May 01, 2018 3:03 pm ]
Post subject:  EXP file not being imported.

We've just started using a new commenting format which places line comments, for example (* Line Commment *) <Code>, before each line rather than at the end to allow online visualization of the code with embedded variables in Codesys 3 to work better, but when used in Codesys V2.3 these new files are exported but not imported at all!!! It just states Import Complete.

If I export a POU, delete it and then import it back the POU remains missing. I've tested this on V2.3.9.42 and V2.3.9.56.

It may be that our comments look like the added comments that Codesys adds int the EXP file, and it's confusing the import.

Code:
(* @NESTEDCOMMENTS := 'Yes' *)
(* @PATH := '\/FN/PRG Blocks\/Misc' *)
(* @OBJECTFLAGS := '0, 8' *)
(* @SYMFILEFLAGS := '0' *)
(* +--------------------------------------------------------------------------------------------+ *)
(* | State Machine Variables and Constants                                                      | *)
(* +--------------------------------------------------------------------------------------------+ *)
(* Full State Machine Update *) FUNCTION StateMC_Update : BOOL
(*                           *)
(* === In/Out Variables ==== *) VAR_IN_OUT
(* Full State Machine Struct *)      tS         : tStateMC;
(*                           *) END_VAR

Any help would be appreciated, as we use Mecurrial, together with these EXP files are part of our new development scheme.

Author:  PJE [ Tue May 01, 2018 3:57 pm ]
Post subject:  Re: EXP file not being imported.

Update:

We've found the issue. If there's a comment before the FUNCTION xxxxx : yyyy or similar then the import fails. Removing the comment from my previously failing import on FUNCTION StateMC_Update : BOOL line allows the import to work correctly.

Obviously, with our overzealous use of start of line comments it may be very easy to add the comment by mistake.

Page 1 of 1 All times are UTC+01:00
Powered by phpBB® Forum Software © phpBB Limited
https://www.phpbb.com/