Sk   En  
 
 
 
 
 
 
 
 

Components of Px Framework:


Events of the PxWebQuery component



The PxWebQuery component contains events that are triggered by the change in state of the component. Each event of the PxWebQuery component can be defined in  the "Page_Load" procedure of the form, where this event shall be triggered.
The definition of the events looks like as follows:

   if ((!IsPostBack)&&(wquAdresar.Active==false))
   {
      ….
      wquAdresar.AfterScroll += new PxControls.AfterScrollEventHandler(wquAdresar_AfterScroll);
      wquAdresar.Open();
      ….
   }
   else
   {
      wquAdresar.AfterScroll += new PxControls.AfterScrollEventHandler(wquAdresar_AfterScroll);
   }


Definition of the "wquAdresar_AfterScroll " procedure, which is called the " AfterScroll " event shall be as follows:

         void wquAdresar_AfterScroll(object sender, EventArgs e)
         {
            lblAdresar.Text = wquAdresar.Fields["name"].ToString();
         }


Each change of the current row cursor, either in the PxWebQuery component or in the PxSuperGrid component, which is linked to the PxWebQuery component, triggers the "AfterScroll event. The "Name" column value of the current row is registered in the Label component for the each event triggered.

The following table contains a summary of all events of the PxWebQuery component.

Event Name Event Description
 BeforeInsert This event is triggered before the execution of the PxWebQuery.Insert () command;
 AfterInsert This event is triggered after the execution of the PxWebQuery.Insert () command;
 BeforeEdit This event is triggered before the execution of the PxWebQuery.Edit () command ;
 AfterEdit This event is triggered after the execution of the PxWebQuery.Edit () command;
 BeforePost This event is triggered before the execution PxWebQuery.Post () command;
 AfterPost This event is triggered after the execution of the PxWebQuery.Post () command;
 BeforeValidPost This event is triggered during the verification of the specified items before the actual data storing by Post () method;
 BeforeOpen This event is triggered before the execution of the PxWebQuery.Open () command;
 AfterOpen This event is triggered after the execution of the PxWebQuery.Open () command;
 BeforeScroll This event is triggered before the change of the row cursor position in the PxWebQuery component
 AfterScroll This event is triggered after the change of the row cursor position in the PxWebQuery component
 BeforeDelete This event is triggered before the execution of the PxWebQuery.Delete() command;
 AfterDelete This event is triggered after the execution of the PxWebQuery.Delete () command;
 BeforeCancel This event is triggered before the execution of the PxWebQuery.Cancel () command;
 AfterCancel This event is triggered after the execution of the PxWebQuery.Cancel () command;
 StateChange This event is triggered during the change in the state of the PxWebQuery component, usually after the execution of the Insert, Edit, Delete, Post, and other commands.
 AfterCreateField This event is triggered after the set up of all the table columns (fields) of the PxWebQuery component. This event is used mainly to create a new dynamic column (field) of the PxWebQuery component table.



Others articles of Px Framework:



It doesn't the intention of this part website, describe in detail the work with PxFramework components, a detailed description of the component available in manual, which can be downloaded here: Download manual of Px Framework

 
  PxWebQuery
  PxSuperGrid
  PxEdit
  PxComboBox
  PxCheckBox
  PxJSDatePicker
  PxDbNavigator
  PxLabel
  PxFlyComboBox
  PxGreatRepeater
  PxChart
  PxUploader
  PxFilterView
  PxCheckBoxList
  PxRadioButtonList
  PxLogin
 
 
  AddParamKey()
  AddParamWebQuery()
  AddParamGreatWeb...
  AddParamCheck()
  AddParamFlyCombo...
  AddParamCheckList()
  AddParamRadioList()
  AddParamValidation()
 
 
  AddParamFilter()