Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

how do I obtain UIMessages in .net without polling the engine

I need to obtain the UIMessages present in the engine without using the polling option.
Please tell me how it can be done
0 Kudos
Message 1 of 3
(3,713 Views)
Good Afternoon Akhalid,
 
It looks like we have a developer zone tutorial that tells how to set up UIMessage handling here: http://zone.ni.com/devzone/cda/tut/p/id/2898.
 
We also have some examples on how to work with UIMessages here: http://zone.ni.com/devzone/cda/epd/p/id/3879.
 
Please let me know if you have any further questions!
 
With warm regards,

David D.
0 Kudos
Message 2 of 3
(3,669 Views)
If I understand you want use event UIMessage :

First in InitializeComponent(), add this line :

 this.axApplicationMgr.UIMessageEvent += new NationalInstruments.TestStand.Interop.UI.Ax._ApplicationMgrEvents_UIMessageEventEventHandler(this.axApplicationMgr_UIMessageEvent);
           
and then in your app add this Method :

 private void axApplicationMgr_UIMessageEvent(object sender, NationalInstruments.TestStand.Interop.UI.Ax._ApplicationMgrEvents_UIMessageEventEvent e)
        {

           
            // If new focus position is send
            if (e.uiMsg.Event == UIMessageCodes.UIMsg_UserMessageBase)
            {
                if (e.uiMsg.NumericData == 1)
                {
                }
        }
}


0 Kudos
Message 3 of 3
(3,659 Views)