Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / General MS InfoPath Questions / March 2007

Tip: Looking for answers? Try searching our database.

Infopath 2007 Event Handlers

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
morna - 14 Mar 2007 16:40 GMT
Where are all the event handlers?  I have an infopath 2007 template
with code behind written in C#.  When I try to find the event handlers
- I only get a very limited set - Validate, Changed textboxs or on the
form.  I see alot of items on the web where others use OnSave or
OnAfterChange, but the code is written in javascript.  How do I gain
access to these other events in C#?

Thanks for your time.
Zhang Haiguang - 14 Mar 2007 17:07 GMT
Here is a demo:
// NOTE: The following procedure is required by Microsoft Office InfoPath.
// It can be modified using Microsoft Office InfoPath.
public void InternalStartup()
{
    EventManager.FormEvents.ViewSwitched += new
ViewSwitchedEventHandler(FormEvents_ViewSwitched);
     ((ButtonEvent)EventManager.ControlEvents["CTRL5_5"]).Clicked += new
ClickedEventHandler(CTRL5_5_Clicked);
    EventManager.FormEvents.Loading += new
LoadingEventHandler(FormEvents_Loading);
    ((ButtonEvent)EventManager.ControlEvents["CTRL6_5"]).Clicked += new
ClickedEventHandler(CTRL6_5_Clicked);
}
Please add your event handlers to EventManager.FormEvents or
EventManager.ControlEvents.

InfoJet Service
InfoPath Web Form
[http://www.infojetsoft.com]
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.