OnAfterChange Question...

V

vb6dev2003

Is there any way to detect the OnAfterChange event on any control on a form
(to avoid having 1 function per control)?

Thanks

vbdev
 
G

G. Tarazi

Of course



This is (an on after change) event on a control:



[InfoPathEventHandler(MatchPath="/ns1:doc/ns1:subsection/ns1:elm1/ns1:elm2",
EventType=InfoPathEventType.OnAfterChange)]

public void methodnamehere_OnAfterChange(DataDOMEvent e)

{

if (e.IsUndoRedo)

{

return;

}

}



This how it will look like if on the entire form:



[InfoPathEventHandler(MatchPath="/ns1:doc",
EventType=InfoPathEventType.OnAfterChange)]

public void methodnamehere_OnAfterChange(DataDOMEvent e)

{

if (e.IsUndoRedo)

{

return;

}

}





The only difference is "MatchPath"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top