04-03-2006 07:46 AM
04-03-2006 07:52 AM
04-03-2006 08:02 AM
Thanks for your answer jaime...
But that's exactly what i want to avoid... I find really useful to write all error messages in an external file. For example if i want to translate my application , i only have to change the Error File. And, if i need to correct a message , i don't have to go in the application, and search for hours every vi concerned by this message...
But as i said, the problem is I think it's not possible to pass parameter with this solution... I hope I'm wrong, cause every modern language allow such things !
04-03-2006 08:37 AM
04-04-2006 03:01 AM
Hi smercurio_fc !
Ok, you were right.. it is maybe not a problem with the language... but this could be easier! As you said, if you want to pass parameters you should write some code... In my case, the function Format into String was not really adapted. I wanted to create a subvi that search the string into the error file and replace the tags by the parameters. But you don't know in advance the number and the type of the parameters. For example in one message you can have 2 doubles as parameters and in the next only one string... In the function "Format into String" you must specify the correct number and types of parameters....
Well, I rewrote a little vi that suit my needs, and it works like I wanted (I pass a array of strings as parameters). But I still think this could be improve....
04-04-2006 10:28 AM
Well, I rewrote a little vi that suit my needs, and it works like I wanted (I pass a array of strings as parameters). But I still think this could be improve....