Click or drag to resize
UniGrid Class
UniGrid base class.
Inheritance Hierarchy

Namespace: CMS.UIControls
Assembly: CMS.UIControls (in CMS.UIControls.dll) Version: 10.0.0
Syntax
C#
public abstract class UniGrid : CMSUserControl, 
	IUniGrid, IObjectTypeDriven, IExtensibleUniGrid, ICallbackEventHandler, IPostBackEventHandler, 
	IUniPageable

The UniGrid type exposes the following members.

Constructors
  NameDescription
Protected methodUniGrid
Top
Fields
  NameDescription
Public fieldStatic memberALL
Constant representing all data source
Public fieldStatic memberCUSTOM_FILTER_SOURCE_NAME
Name of the custom filter control set via GridOptions.FilterPath. Custom filter can be accessed by FilterFields[CUSTOM_FILTER_SOURCE_NAME].
Protected fielddataSourceIsUsed
Indicates whether external data source is used.
Protected fielddisplayFilter
Indicates whether a filter should be displayed above the UniGrid. If the amount of displayed rows is lower than the value of the FilterLimit key, the filter will be hidden despite this setting. Loaded from UniGrid options.
Protected fieldonActionUsed
Indicates whether UniGrid action was raised. Used for data reloading.
Protected fieldpagerForceNumberOfResults
Total number of available records returned from data reload.
Protected fieldqueryStringHashTable
Dictionary of where conditions by filters for filtering by query parameters. Filter name = Where condition.
Public fieldStatic memberSELECTALL_EXTERNAL_DATABOUND
Select all external source name. Used for header external DataBound of SelectAll check box.
Public fieldStatic memberSELECTION_EXTERNAL_DATABOUND
Selection external source name. Used for external DataBound of selection column.
Protected fieldshowSelection
Indicates whether a column allowing the selection of rows should be displayed on the left of the UniGrid. Loaded from UniGrid options.
Protected fieldshowSortDirection
Determines if an arrow showing the sorting direction should be displayed next to the header of the column used for sorting. Loaded from UniGrid options.
Top
Properties
  NameDescription
Protected propertyActionsHashHidden
Hidden field with hashed action ids.
Protected propertyActionsHidden
Hidden field with action ids.
Public propertyActionsID
Array list of actions on current page of UniGrid.
Protected propertyAdvancedExportControl
Returns the advanced export control of the current grid
Public propertyAllColumns
Allows to explicitly specify all columns that can be retrieved from UniGrid Comma-separated value e.g. "ItemID, ItemName"
Public propertyApplyPageSize
Determines whether to apply CurrentPageSize when retrieving data.
Protected propertyCmdArgHiddenField
Hidden field for the command argument
Protected propertyCmdNameHiddenField
Hidden field for the command name
Public propertyColumns
Columns to get from the database.
Public propertyCompleteWhereCondition
Returns the complete where condition.
Public propertyComponentName
Component name
(Inherited from AbstractUserControl.)
Public propertyControlContext
Control context.
(Inherited from CMSUserControl.)
Public propertyControlGUID
Unique ID of the control within the given request.
(Inherited from CMSUserControl.)
Public propertyCurrentDocument
Current document
(Inherited from AbstractUserControl.)
Public propertyCurrentOffset
Gets current offset.
Protected propertyCurrentOrder
Gets current order by.
Public propertyCurrentPageInfo
Current page info
(Inherited from AbstractUserControl.)
Protected propertyCurrentPageSize
Gets current page size from pager.
Public propertyCurrentResolver
Control's resolver
(Inherited from CMSUserControl.)
Public propertyCurrentSite
Current site
(Inherited from AbstractUserControl.)
Public propertyCurrentTopN
Number of records to display (load). It's being set before ReloadData event is fired in order to optimize the data loading.
Public propertyCurrentUser
Current user
(Inherited from AbstractUserControl.)
Public propertyCustomFilter
Custom filter control
Public propertyDataSource
External grid DataSource, when set, overrides the default data source settings.
Public propertyDataSourceIsSorted
Indicates if data source is sorted outside of UniGrid.
Public propertyDefaultImageDirectoryPath
Gets default image directory path for images.
Public propertyDelayedReload
Indicates if delayed reload should be used. If True reload data must be called externally.
Public propertyDeselectedItems
Gets deselected items from UniGrid.
Public propertyDialogHeight
Height of
Public propertyDialogWidth
Width of edited dialog
Public propertyDisplayMode
Gets or sets display mode of the control.
(Inherited from CMSUserControl.)
Public propertyDocumentManager
Document manager control
(Inherited from AbstractUserControl.)
Public propertyEditActionUrl
URL for the edit action handling.
Public propertyEditedObject
Control's edited object
(Inherited from CMSUserControl.)
Public propertyEditInDialog
If true, the editing action is done through a dialog
Public propertyExportFileName
Name used for exporting files (without extension).
Public propertyFilterByQueryString
True if the filtering should be set from the query string parameters.
Public propertyFilterDirectoryPath
Gets or sets directory path for custom filter controls.
Public propertyFilteredZeroRowsText
Text displayed when UniGrid data source is empty after filtering.
Public propertyFilterForm
Gets filter form.
Public propertyFilterFormData
Data container for filter form.
Public propertyFilterFormName
This name is used for alternative form.
Protected propertyFilterFormPlaceHolder
Returns the filter form placeholder
Public propertyFilterIsSet
Indicates if filter is set. It's being used when filter by query string is used.
Public propertyFilterLimit
Minimal count of entries for display filter. 0 means that filter is displayed always and -1 means that filter is never displayed.
Public propertyFilterMode
Filter mode passed to custom filters.
Public propertyFilterPlaceHolder
Gets filter placeHolder from UniGrid.
Public propertyGridActions
Actions definition.
Public propertyGridColumns
Columns definition.
Public propertyGridMassActions
Mass actions definition.
Public propertyGridName
Xml file with source information.
Public propertyGridOptions
Options.
Public propertyGridView
Grid view used by UniGrid.
Public propertyGroupObject
Indicates if the object type is community group related.
Protected propertyHasDefaultState
Gets the value indicating whether UniGrid is in a default state, i.e., without filtering condition, on the first page and with the default page size and sorting order.
Public propertyHeaderActions
Header actions control
(Inherited from AbstractUserControl.)
Protected propertyHeaderPanel
Returns the grid header panel
Public propertyHideControlForZeroRows
Indicates whether hide UniGrid or not when its data source is empty.
Public propertyHideFilterButton
Indicates whether hide filter "Show" button or not.
Public propertyCheckRelative
If true, relative ancestor div is checked in context menu
Public propertyImageDirectoryPath
Gets or sets directory path for images.
Protected propertyInfoLabel
Grid information label
Public propertyInfoObject
Gets instance of info object based on ObjectType property.
Public propertyIsCMSDesk
Determines whether the current control lies on the page that is currently located under the CMS Desk.
(Inherited from CMSUserControl.)
Public propertyIsEmpty
Indicates if the data source is empty.
Public propertyIsLiveSite
Indicates if control is used on live site
(Overrides AbstractUserControlIsLiveSite.)
Public propertyItem
Gets or sets the value of the column.
(Inherited from InlineUserControl.)
Public propertyJavaScriptModule
Path to JavaScript module that will be loaded for this grid.
Public propertyJavaScriptModuleData
Data that will be sent to the grid's JavaScript module.
Public propertyMacro
If defined, uses this macro to retrieve the grid data source. The macro must return IDataQuery object. Macro source has higher priority than object type.
Public propertyMassActions
Control containing mass actions.
Protected propertyMenuPlaceHolder
Gets the menu placeholder
Public propertyMessagesPlaceHolder
Placeholder for messages
(Inherited from AbstractUserControl.)
Public propertyNamedColumns
Gets named columns from grid view.
Public propertyNewlySelectedItems
Gets newly selected items from UniGrid.
Public propertyObjectType
Object type which is loaded to the grid
Public propertyOrderBy
Order columns.
Protected propertyOrderByRegex
Description.
Protected propertyOriginallySelected
Gets array list of originally selected items.
Public propertyPager
UniGrid pager used by UniGrid.
Public propertyPagerConfig
Pager configuration.
Public propertyPagerDataItem
Pager data item.
Public propertyPagerFirstPageText
Text displayed in pagers first page link.
Public propertyPagerForceNumberOfResults
Volume of returned records.
Public propertyPagerLastPageText
Text displayed in pagers last page link.
Public propertyPagerNextGroupText
Text displayed in pagers next group link.
Public propertyPagerNextPageText
Text displayed in pagers next page link.
Public propertyPagerPreviousGroupText
Text displayed in pagers previous group link.
Public propertyPagerPreviousPageText
Text displayed in pagers previous page link.
Public propertyPageSize
UniGrid page size values separated with comma. Default: 5,10,25,50,100
Public propertyPageSizeDropdown
Gets page size dropdown from UniGrid.
Public propertyParameter
Inline control parameter - mirrors the GridName property.
(Overrides InlineUserControlParameter.)
Protected propertyProperties
Control properties.
(Inherited from InlineUserControl.)
Public propertyQuery
Query used in grid view.
Public propertyQueryParameters
Query parameters for the query.
Public propertyRelativePath
Page relative path.
(Inherited from CMSUserControl.)
Public propertyRememberDefaultState
Indicates whether UniGrid remembers its default state.
Public propertyRememberState
Gets or sets the value indicating whether UniGrid remembers its state, i.e., filter, page number, page size and sorting order.
Public propertyRememberStateByParam
Gets or sets a comma-separated list of names of query parameters whose value constitute a part of UniGrid's identity.
Public propertyCode exampleResourcePrefix
Prefix for the resource strings which are used for the localization by the control and its child controls.
(Inherited from AbstractUserControl.)
Public propertyResourcePrefixes
List of cached resource prefixes for the parent hierarchy
(Inherited from AbstractUserControl.)
Public propertyRowsCount
Gets rows count from DataSet. Sets after ReloadData().
Public propertySelectedItems
Gets or sets selected items of UniGrid. Returns empty collection if hash validation fails.
Protected propertySelectionHashHiddenField
Hidden field containing selected items hash.
Public propertySelectionHiddenField
Hidden field containing selected items.
Public propertySelectionJavascript
Name of javascript function called after selection checkbox is clicked. First argument will be value of selection column or first column in data source. Second argument will be true/false according to checkbox.
Public propertySelectionsID
Array list of selection ids of UniGrid.
Public propertyShortID
Short ID of the control.
(Inherited from AbstractUserControl.)
Public propertyShowActionsLabel
If true, the actions label is displayed
Public propertyShowActionsMenu
Defines whether to show actions menu (menu in the header row of actions column).
Public propertyShowExportMenu
Defines whether to show export menu (menu in the header row of actions column).
Public propertyShowFilter
If count of rows is greater or equal to filter limit, show filter.
Public propertyShowObjectMenu
Defines whether to show object menu (menu containing relationships, export/backup, destroy object, ... functionality)
Protected propertySortColumns
Gets sort columns from grid view.
Public propertySortDirect
Sort directive used in grid view.
Protected propertyStateRestored
Gets or sets the value indicating whether UniGrid has restored its state.
Public propertyStopProcessing
Indicates if the control should perform the operations.
(Inherited from AbstractUserControl.)
Public propertyTextColumns
Array list of text columns used in sorting when query is used.
Public propertyTopN
Number of records to display (load).
Public propertyTypeName
Returns the object type name.
(Inherited from CMSUserControl.)
Public propertyUIContext
Control's UI Context
(Inherited from CMSUserControl.)
Public propertyUniPagerControl
Pager control.
Public propertyUseCMSDeskAccessDeniedPage
Gets or sets the value that indicates whether CMSDesk access denied page should be used.
(Inherited from CMSUserControl.)
Public propertyUsesLocalMessagesPlaceHolder
Indicates if control uses local messages placeholder
(Inherited from AbstractUserControl.)
Protected propertyViewState
ViewState - overridden for the Master page ViewState fix.
(Inherited from InlineUserControl.)
Public propertyWhereClause
Where clause used in grid view.
Public propertyWhereCondition
Where condition that can be set from other classes.
Public propertyZeroRowsText
Text displayed when UniGrid data source is empty.
Top
Methods
  NameDescription
Public methodAddAdditionalColumn
Adds column to the UniGrid's columns with optional callback which specifies what will be displayed in a column cells.
Public methodAddColumn
Add new basic column into grid view.
Public methodAddConfirmation
Adds confirmation text to existing message on the page.
(Inherited from AbstractUserControl.)
Public methodAddError
Adds error text to existing message on the page.
(Inherited from AbstractUserControl.)
Public methodAddHeaderAction
Adds specified action to the page header actions.
(Inherited from AbstractUserControl.)
Public methodAddInformation
Adds information text to existing message on the page.
(Inherited from AbstractUserControl.)
Public methodAddMessage
Adds message text to existing message on the page.
(Inherited from AbstractUserControl.)
Public methodAddWarning
Adds warning text to existing message on the page.
(Inherited from AbstractUserControl.)
Public methodApplyFilter
Applies current filter where condition.
Public methodClearActions
Clears UniGrid's information on recently performed action. Under normal circumstances there is no need to perform this action. However sometimes forcing grid to clear the actions is required.
Public methodDisplayExternalFilter
Determines whether to show external filter.
Public methodEnsureControls
Interface for control that is able to explicitly ensure its child controls
(Inherited from AbstractUserControl.)
Public methodEval(String)
Evaluates the given value
(Inherited from AbstractUserControl.)
Public methodEval(String, Boolean)
Evaluates the item data (safe version), with html encoding.
(Inherited from AbstractUserControl.)
Public methodEvalBool
Evaluates the item data and converts it to the bool.
(Inherited from AbstractUserControl.)
Public methodEvalDateTime
Evaluates the item data and converts it to the date time.
(Inherited from AbstractUserControl.)
Public methodEvalDouble
Evaluates the item data and converts it to the integer.
(Inherited from AbstractUserControl.)
Public methodEvalGuid
Evaluates the item data and converts it to the guid.
(Inherited from AbstractUserControl.)
Public methodEvalHTML
Evaluates the item data and doesn't encode it. Method should be used for columns with html content.
(Inherited from AbstractUserControl.)
Public methodEvalHtmlAttribute
Evaluates the item data, encodes it to be used in HTML attribute.
(Inherited from AbstractUserControl.)
Public methodEvalInteger
Evaluates the item data and converts it to the integer.
(Inherited from AbstractUserControl.)
Public methodEvalJSString
Evaluates the item data, encodes it to be used in javascript code and encapsulates it with "'".
(Inherited from AbstractUserControl.)
Public methodEvalText(String)
Evaluates the item data and encodes it. Method should be used for columns with string nonhtml content.
(Inherited from AbstractUserControl.)
Public methodEvalText(String, Boolean)
Evaluates the item data and encodes it. Method should be used for columns with string nonhtml content.
(Inherited from AbstractUserControl.)
Protected methodGetAccessDeniedPageUrl
Returns access denied page with dependence on current setting.
(Inherited from CMSUserControl.)
Protected methodGetActionImage
Returns icon file for current theme or from default if current doesn't exist.
Public methodGetCallbackResult
Returns callback result.
Public methodGetClearSelectionScript
Gets JavaScript for clearing selection of the grid.
Protected methodGetConfigurationXml
Returns XML document from given path.
Public methodGetFilter
Returns where condition from UniGrid filters.
Public methodGetFlagIconUrl
Returns resolved path to the flag image for the specified culture.
(Inherited from AbstractUserControl.)
Public methodGetCheckDependenciesDescription
Gets description for error message when dependencies check fails.
Public methodGetCheckSelectionScript
Gets JavaScript for checking selection of the grid.
Public methodGetImagePath
Gets UI image relative path.
(Inherited from AbstractUserControl.)
Public methodGetImageUrl
Gets UI image relative path.
(Inherited from AbstractUserControl.)
Public methodGetJSModule
Gets the JS module representing the UniGrid
Public methodGetReloadScript
Gets JavaScript for reload of the grid.
Public methodGetSelectionFieldClientID
Gets identifier of field containing selected items.
Public methodGetString
Returns the localized string of the control's hierarchically highest parent that has the ResourcePrefix property and its translation defined.
(Inherited from AbstractUserControl.)
Public methodGetValue(String)
Returns the value of the given property.
(Inherited from InlineUserControl.)
Public methodGetValueReturnType(String, ReturnType)
Returns the value of the given property.
(Inherited from InlineUserControl.)
Public methodHandleAction
Handles the action event.
Protected methodHandleVisibility
Handles the display of the grid based on whether the data is loaded or not
Public methodHasValue
Returns true if the value of the given property is set.
(Inherited from InlineUserControl.)
Protected methodIsInternalPostBack
Returns true if current request was fired by page change or filter show button.
Protected methodLoadActionsDefinition
Loads actions definition.
Protected methodLoadColumnDefinition
Load single column definition.
Protected methodLoadFilterControl
Loads the filter control
Protected methodLoadGrid
Loads the grid
Public methodLoadGridDefinition
Loads the grid definition.
Protected methodLoadMassActionsDefinition
Loads mass actions definition.
Protected methodLoadOptionsDefinition
Load options definition.
Protected methodLoadPagerDefinition
Load UniGrid pager configuration.
Public methodLoadUserControl
Loads the user control based on the given path
(Inherited from AbstractUserControl.)
Public methodLoadXmlConfiguration
Loads the XML configuration of the grid.
Public methodLogAndShowError
Logs the exception and
(Inherited from AbstractUserControl.)
Protected methodMapPathInternal
Returns the physical file path that corresponds to the specified virtual path.
Public methodOnContentLoaded
Method that is called when the control content is loaded.
(Inherited from InlineUserControl.)
Protected methodOnInit
Init event handler.
(Overrides AbstractUserControlOnInit(EventArgs).)
Protected methodOnLoad
Load event handler.
(Overrides CMSUserControlOnLoad(EventArgs).)
Protected methodOnPreRender
PreRender event handler.
(Overrides AbstractUserControlOnPreRender(EventArgs).)
Protected methodProcessSorting
Sets the sort direction if current request is sorting.
Public methodRaiseAction
Raises the action event.
Public methodRaiseAfterRetrieveData
Raises after data are retrieved.
Public methodRaiseBeforeFiltering
Raises the before filtering event.
Public methodRaiseBeforeSorting
Raises the before page index changing event.
Public methodRaiseCallbackEvent
Sets callback event arguments.
Public methodRaiseDataReload
Raises the reload data event and returns DataSet.
Public methodRaiseExternalDataBound
Raises the external data bound event.
Public methodRaiseLoadColumns
Raises when columns are loaded dynamically and not from XML.
Public methodRaiseOnAfterDataReload
Raises the after data reload event.
Public methodRaiseOnBeforeDataReload
Raises the before data reload event.
Public methodRaiseOnFilterFieldCreated
Raised when filter field is created.
Protected methodRaiseOnPageBinding
Raises the OnPageBinding event
Public methodRaisePageSizeChanged
Raises the after page size dropdown changed.
Public methodRaisePostBackEvent
Raises the postback event
Public methodRaiseShowButtonClick
Raises the before page index changing event.
Public methodReBind
Evokes control DataBind.
Public methodRedirectToAccessDenied(String)
Redirects the user to Access denied page.
(Inherited from CMSUserControl.)
Protected methodRedirectToAccessDenied(Int32, String)
Redirects the user to Access denied page.
(Inherited from CMSUserControl.)
Protected methodRedirectToAccessDenied(String, String)
Redirects the user to Access denied page.
(Inherited from CMSUserControl.)
Protected methodRedirectToUIElementAccessDenied
Redirects the user to Access denied page.
(Inherited from CMSUserControl.)
Protected methodRegisterCmdScripts
Register UniGrid commands scripts.
Public methodReleaseContext
Releases the control context.
(Inherited from CMSUserControl.)
Public methodReloadData
Reloads the grid data.
Protected methodRender
Render event handler.
(Inherited from AbstractUserControl.)
Public methodReset
Resets the UniGrid state, i.e., restores the filter to the initial state, navigates to the first page and sets the default page size and sorting order, and finally reloads data.
Public methodResetSelection
Uncheck all checkboxes in selection column.
Public methodStatic memberResetStates
Resets the state of all Unigrids displaying objects of given type.
Public methodResolveUrl
Resolves the given URL
(Inherited from AbstractUserControl.)
Protected methodRestoreState
Restores the UniGrid's state, if applicable.
Public methodRetrieveData
Gets a DataSet with data based on UniGrid's settings.
Protected methodSetActionsHash
Sets hidden field with actions hashes.
Protected methodSetBasicFormFilter
Sets basic form filter.
Public methodSetContext
Sets the control context.
(Inherited from CMSUserControl.)
Protected methodSetFilter
Sets filter to the grid view and save it to the view state.
Protected methodSetPager
Sets pager control.
Protected methodSetUnigridControls
Sets UniGrid controls.
Protected methodSetupGridRow
Sets up an individual grid row
Public methodSetValue
Sets the property value of the control, setting the value affects only local property value.
(Inherited from InlineUserControl.)
Public methodShowConfirmation
Shows the general confirmation message.
(Inherited from AbstractUserControl.)
Public methodShowError
Shows the specified error message, optionally with a tooltip text.
(Inherited from AbstractUserControl.)
Public methodShowChangesSaved
Shows the general changes saved message.
(Inherited from AbstractUserControl.)
Public methodShowInformation
Shows the given information on the page, optionally with a tooltip text.
(Inherited from AbstractUserControl.)
Public methodShowMessage(MessageTypeEnum, String, String, String, Boolean)
Shows the specified message, optionally with a tooltip text.
(Inherited from AbstractUserControl.)
Protected methodShowMessage(MessageTypeEnum, String, String, String, Boolean, Boolean)
Shows the specified message, optionally with a tooltip text.
(Inherited from AbstractUserControl.)
Public methodShowWarning
Shows the specified warning message, optionally with a tooltip text.
(Inherited from AbstractUserControl.)
Protected methodSortUniGridDataSource
Sorts UniGrid data source according to sort directive saved in ViewState.
Protected methodStoreState
Stores the UniGrid's state, if applicable.
Protected methodTrackViewState
Tracks the view state.
(Inherited from InlineUserControl.)
Top
Extension Methods
  NameDescription
Public Extension MethodCallHandled
Calls the method handled by the exception handler. If the call doesn't succeed, the problem is reported through parent IExceptionHandler control instead of throwing unhandled exception for the entire page. Returns true, if the call succeeded, otherwise returns false.
(Defined by ControlsExtensions.)
Public Extension MethodGetString
Gets the string by the specified resource key
(Defined by ControlsExtensions.)
Top
Events
  NameDescription
Public eventOnAction
Event raised on action post back.
Public eventOnAfterDataReload
Event raised after data are reloaded from external data source.
Public eventOnAfterRetrieveData
Raised when after data are retrieved.
Public eventOnBeforeDataReload
Event raised before data are reloaded from external data source.
Public eventOnBeforeFiltering
Raised before filtering from UniGrid filter is called.
Public eventOnBeforeSorting
Raised before sorting is called.
Public eventOnDataReload
Event raised when data are reloaded from external data source.
Public eventOnExternalDataBound
Event raised when external source data required.
Public eventOnFilterFieldCreated
Raised when filter field is created.
Public eventOnLoadColumns
Raised when columns are loaded dynamically and not from XML.
Public eventOnPageBinding
Occurs when the control bind data.
Public eventOnPageChanged
Occurs when the pager change the page and current mode is postback => reload data
Public eventOnPageSizeChanged
Raised on page size changed.
Public eventOnShowButtonClick
OnShowButtonClick event handler.
Top
See Also