01-15-2009 02:08 AM
Solved! Go to Solution.
01-19-2009 03:40 AM
Hi,
it tested your bothe CVI User Interface Examples with the Teststand 4.x ivi and property loader examples from
C:\Dokumente und Einstellungen\All Users\Dokumente\National Instruments\TestStand 4.1\Examples\IVI
C:\Dokumente und Einstellungen\All Users\Dokumente\National Instruments\TestStand 4.1\Examples\PropertyLoader
The Property Loader example works without errors and the IVI example gives a similar error because i had not set the right IVI Settings in MAX (MeasureAutomationExplorer).
When i set it here right - then no error with both User Interfaces. Please test your *.seq first in Sequence Editor - when you had here no error - then test it in the User Interfaces.
Did you test it in Sequence Editor and what version do you have ? Have you test the existing teststand examples ?
Can you attache here your special *.seq file ?
Best Regards
01-19-2009 03:52 AM
The error 1073807195 said, that you called the wrong ressource name in IVI step. Therefore you must look in MAX -> My System -> IVI drivers -> Driver Sessions -> Hardware.
In the Hardware field you see a Ressource Descriptor. The name muste be the Name of Card unter MySystem -> Device and Interfaces -> NI DaqMx or the Name of PXI like in the screenshot i attached here. So the error comes not from your user interface...
Best Regards
01-20-2009 03:32 AM
Hello Johann,
I am not sure that you have understood my problem. My problems are not the error messages of the IVI drivers and property loader!! But my problem is, that error messages of IVI drivers and property loader one operator interface brings not on the screen. So to test this you have to provoke an error message of IVI driver or property loader, then you can see that with the one OI you have an error message and with the other OI no error message occures and the test stocks without a message. Do you know why this OI does not show the error messages and how showing the error message can be implemented in this operator interface
regards
Samuel
01-22-2009 03:33 AM
Hi Samuel,
the first OI looks like the simple OI whose had most features not implemented as the full featured OI. For those you must use an SequenceFailure/StepFailurePost callback whose similar functions should find in tesstand library. Additionally it can be that you need an additionally activeX indicator (find in ActiveX -> Teststand API).
I´ve done similar modifying in Labview but not yet in Labwindows/CVI. Must try it the next days.
Best Regards
01-23-2009 02:00 AM
Hello Johann,
Thank You for your answer.
Is it possible that you give me a feedback, when you have tried it in the next days?
regards
Samuel
01-23-2009 09:55 AM
you must implement the error callback - attached here a small example. You can compare the testexec.c with simple.c and see it
HRESULT CVICALLBACK ApplicationMgr_OnDisplayExecution(CAObjHandle caServerObjHandle, void *caCallbackData, TSUIObj_Execution execution, enum TSUIEnum_ExecutionDisplayReasons reason)
{
int error = 0;
// bring application to front if we hit a breakpoint
if (reason == TSUIConst_ExecutionDisplayReason_Breakpoint || reason == TSUIConst_ExecutionDisplayReason_BreakOnRunTimeError)
errChk( SetActivePanel(gPanel));
Error:
DisplayError(error);
return error < 0 ? E_FAIL : S_OK;
}
static void DisplayError(int errorCode)
{
if (errorCode < 0)
{
TS_DisplayError(errorCode, errMsg, gEngine); // errMsg is a global, see top of file
ClearErrorMessage();
}
}
static void ClearErrorMessage(void)
{
// clear out error message globals so that a future error that lacks an error description does not
// unintentionally use the error description from a prior error.
*errMsg = '\0';
memset(&errorInfo, 0, sizeof(ERRORINFO));
}
01-26-2009 03:58 AM
Hello Johann,
I have implemented your suggestion and I get some information in a teststand sequence error window (see right side of attached jpg file) when using the operator interface. On the left side of the attached jpg file you see the error windows the teststand sequence editor gives for the same error. As you can see the windows on the right side do not contain the fields "Error Code" and "Location". Do you know a idea how to implement this?
Thank You
regards
Samuel
01-26-2009 08:22 AM
Hi Samuel,
not all Callbacks/ActiveXControls have all Properties/Methods you wants to have. For this you can look in the FullFeatured User Interface of Labwindows/CVI
for finding a similar solution for your own User Interface (Operator Interface)
C:\Programme\National Instruments\temp\TestStand 4.1\UserInterfaces\Full-Featured\CVI
or in the API Reference Poster for programmatically reading the Error Cluster (ErrorCode, Error Description and ErrorOccured)
via Methods/Properties
C:\Programme\National Instruments\temp\TestStand 4.1\Doc\Manuals
You can also set a property object to a Step or the Current Execution and then use LookupString for getting the Error Cluster e.g.
RunState.Sequence.Main["StepName"].Result.Error.Code
So more ways to solution. But needs time and practise for implementation when you not do it before
Best Regards