public void DataBindingContexts(Application.FormControl_DataBindingContexts_Completed eventHandler) { dataBindingContextsIsLoaded = false; if (dataBindingContextsIsLoaded) { Server.Application.FormControl_DataBindingContextsCompletedEventArgs completedEventArgs; completedEventArgs = new Server.Application.FormControl_DataBindingContextsCompletedEventArgs( new Object[] { dataBindingContexts }, null, false, null); if (eventHandler != null) { eventHandler(this, completedEventArgs); } } else { Server.Application.ApplicationClient client = Application.ApplicationClient; client.FormControl_DataBindingContextsCompleted += new EventHandler <Server.Application.FormControl_DataBindingContextsCompletedEventArgs> (DataBindingContexts_Completed); client.FormControl_DataBindingContextsCompleted += new EventHandler <Server.Application.FormControl_DataBindingContextsCompletedEventArgs> (eventHandler); Server.Application.Form serverForm = (Server.Application.Form)Form.ToServerObject(); client.FormControl_DataBindingContextsAsync(Application.Session.Token, serverForm, controlId); } return; }
public void DataBindingContexts_Completed(Object sender, Server.Application.FormControl_DataBindingContextsCompletedEventArgs eventArgs) { dataBindingContexts = eventArgs.Result; dataBindingContextsIsLoaded = true; return; }