Hi everyone!
For my proyect, I need to locate the digital input/output long texts, but i have no idea where can be stored. Anyone knows it?
thanks in advance!!!
long texts in KRC 4
-
Lugion11 -
November 5, 2018 at 8:40 PM -
Thread is marked as Resolved.
-
-
Hi everyone!
For my proyect, I need to locate the digital input/output long texts, but i have no idea where can be stored.
What do you mean by 'I need to locate', what exactly do You want to do?
You can export the longtext to a CSV file. -
Hi hermann, i need to know where is stored the longtext content, i mean, the location in the system of that data. If is in a especific file in windows or in a configuration file.
-
don't know (or care) where it is stored but one can easily generate it (export) using HMI or WoV.
-
Describe the reason. Why Do you need to know the location. May be there is a different solution for the task.
-
it's for a type of message I am working on, to be able to emulate a WAIT FOR message and display the longtext insted of only the signal number.
-
why not use SIGNAL?
-
It's because we need to modify the behavior of the WAIT FOR message, to display that message in a rutine diferent from the one that trigger the WAIT FOR. I don't know if I explained it clearly.
-
Not very clearly, no. If you post a State message "from another routine," the WAIT FOR command is still going to post its own WAITING FOR (Signal) message. There's no way to stop that.
On the rare occasions when I've needed to do something like this in the past, I've usually simply written my own message, posted it directly, and then used a REPEAT loop instead of a WAIT.
-
May be the undocumented funtion GET_SIG_INF("SIGNALNAME") can help.
The function returns informations about the signalname given to the funtion.Code
Display MoreSIGNAL INPUT1 $in[1] DECL SIGINF inp DECL char signame[] signame[] = "INPUT1" inp=GET_SIG_INF(signame[]) if $in[inp.idx] then Message("input "+signame+" is TRUE") ; PSEUDOCODE !! else Message("input "+signame+" is FALSE") ; PSEUDOCODE !! endif
Written from scratch, so may be full of errors. Just to give a clue.
Signame can be the parameter for Your own procedure. The problem is that You have to give the name of the declared signal, and if you have a typing error you will get a message not during compile time but later at run time.You don't have the long text, but the signal name declared in $config.dat or somewhere else.