06-13-2014 10:12 AM
I created a custom error code file on my development machine and included in my build. Is there a way to access this custom error code file on my target??
I know the directory struct is different on the target and made the mistake of hard coding in the path on my devellopment machine. What I'm trying to do is print out the custom error if and when the test encounters one. I could create a custom error code.txt then look for the right error code then send it to the print...which is what I do on the development machine but how is it done on a target??
06-13-2014 10:25 AM
If you create an error file in LV (Tools->Advanced->Edit Error Codes...) and then include the file you create in the project, you can connect that file to the executable in the application builder. Is this what you are talking about?
Mike...
06-13-2014 10:35 AM
kind of...doesn't the exe/build/installer/project ( on my development machine) bundle all that data such that I don't have access to it?? If I included the custom error code in my build/installer what directory is it in on my target?? If I encounter an error on my target I want to print out that custom error. How would you do that? I don't know where the custom error file is on my target to point my print out vi to it so it can get that code ( after seaching the custom error code.txt file)
I edited/modified it on my develope so I knew where it was. I then hard coded my path in my print out vi to that directory struct. When I port my exe to my target that directory struct is no longer valid.
My question is can I use the custom error codes in my exe some how to print out the current error
OR
would I be better off porting over the custom error code.txt to a known directory on my target then hard coding it in on my developement machine...making both dir struct the same on develop and target
06-13-2014 10:46 AM
That's the beauty of using the error files, once built into an executable all your custom errors get handled and reported just like LV's built-in errors. Nothing to search for.
Mike...
06-13-2014 10:56 AM
Say custom error 8050 is "25 vdc power supply is low." how do I print that out ?? send it to my test set printer?
06-13-2014 11:04 AM
The same way you would a built-in error code. For example, in the error handler that NI created there's a subVI that given a number returns an error description. You can use that.
Mike...