Class: cSigCJPropertyGridItem

Module location: cSigCJPropertyGrid.pkg line 989 (view source)

--------------------------------------------------- Class : cSigCJPropertyGridItem Superclass : cSigCjComPropertyGridItem Package : cSigCJPropertyGrid.pkg Mixins : cSigCJPropertyGridItem_Mixin Description : Represents an item in the Property Grid. Properties : psLabel (String) psHelpText (String) psToolTip (String) pbCreateExpanded (Boolean) pbLabelEmboldened (Boolean) peItemType (Integer) pvValue (Variant) pbDefaultAsInitialValue (Boolean) pvDefaultValue (Variant) pvInitialValue (Variant) pvTag (Variant) pbHidden (Boolean) pbReadOnly (Boolean) pbPassword_State (Boolean) pbCapslock_State (Boolean) piForm_Margin (Integer) piValueBackgroundColor (Integer) psImage (String) psFormat (String) READ-ONLY *** Item_Server (Handle) Item_Data_Field (Integer) Events : OnChange OnEditAfter OnMoveItemDataIn OnMoveItemDataOut Methods : Procedure Set PropertyItemMask (String llMask String llLiteral Variant llPrompt) Procedure BindToDatabase (integer hFile integer iField) MoveItemDataToDatabase ReadItemFromDatabase Notes : Example call of BindToDatabase: Send BindToDatabase File_Field Sysfile.Field_1 To Do : ---------------------------------------------------

Class Hierarchy:

DFCOMAUTOMATIONOBJECTcComAutomationObjectcSigCjComPropertyGridItemcSigCJPropertyGridItem

Mixins:

cSigCJMethods_Mixin, cSigCJPropertyGridItem_Mixin,

Direct Known Subclasses:

cSigCJPropertyGridComboFormItem, cSigCJPropertyGridExpandBtnItem, cSigCJPropertyGridSliderCtlItem, cSigCJPropertyGridSpinFormItem, cSigCJPropertyGridSubCategory,

Class Definition

Properties

BooleanpbDefaultAsInitialValue
BooleanPrivate.pbCapslock
BooleanPrivate.pbHidden
BooleanPrivate.pbIsPassword
BooleanPrivate.pbReadOnly
IntegerPrivate.peItemType
HandlePrivate.phoPropertyGridItemServer
If this item is linked to a field in a database, we may like properties to store the server and field values
IntegerPrivate.piFormMargin
IntegerPrivate.piPropertyGridItemDataField
IntegerPrivate.piValueBackgroundColor
StringPrivate.psFormat
VariantPrivate.pvDefaultValue
VariantPrivate.pvTag
VariantPrivate.pvValue
tdPropertyItemMaskptPropertyItemMask

Functions and Procedures

BindToDataBase(Integer hFile Integer iField)
--------------------------------------------------- Procedure : BindToDataBase Scope : Public Paramaters : iFile iField Returns : None Purpose : Links a grid item with the db (file and field). Sets Private.phoPropertyGridItemServer and Private.piPropertyGridItemDataField Notes : If an item is linked to the db, pbCapslock_State and piForm_Margin will be set automatically. If you don't Set psLabel or psHelpText these too will be taken from the DD Example Call: Send BindToDataBase File_Field Sysfile.Company_Name ---------------------------------------------------
Construct_Object()
Inherited from cSigCjComPropertyGridItem
DoApplyMask()
--------------------------------------------------- Procedure : DoApplyMask Scope : Private Paramaters : None Returns : None Purpose : Called from Private.Create. Applies any mask set using 'Set PropertyItemMask' Notes : Called internally. Developer does not need to concern themself with this ---------------------------------------------------
End_Construct_Object()
IntegerItem_Data_Field()
HandleItem_Server()
Create and augment procedures and functions
MoveItemDataToDatabase()
--------------------------------------------------- Procedure : MoveItemDataToDatabase Scope : Public Paramaters : None Returns : None Purpose : If item is bound to the database (file and field) it will simply set the field_changed_value of the item's server DDO with the value of the property grid item. Notes : Could be Broadcast as part of a save process. Take care however. If the item has a combo form it MAY be that you DON'T want to save the value (decription) but instead would want to save the itemdata or code value! If this is the case, the method can be augmented in the item object to "Get CodeFromDescription" of whatever ---------------------------------------------------
OnChange()
OnChange Called whenever an item's value is changed and user exists the item
OnEditAfter(String ByRef llNewValue Boolean ByRef llCancel)
OnEditAfter Called whenever an item's value has been editted. Setting llCancel to True will stop the edit
OnMoveItemDataIn()
OnMoveItemDataIn Called from DoMoveDataIn (of the property grid). This is called from OnCreate and can be used to set item data (appy from database,say)
OnMoveItemDataOut()
OnMoveItemDataOut Called from DoMoveDataOut (of the property grid). This can be used to save item data to the database, say
BooleanpbCapslock_State()
BooleanpbHidden()
BooleanpbPassword_State()
BooleanpbReadOnly()
StringpeItemType()
IntegerpiForm_Margin()
IntegerpiValueBackgroundColor()
Private.Create(Handle hoParent Boolean bRecursive)
StringpsFormat()
StringpvDefaultValue()
StringpvTag()
StringpvValue()
ReadItemFromDatabase()
--------------------------------------------------- Procedure : ReadItemFromDatabase Scope : Public Paramaters : None Returns : None Purpose : If item is bound to the database (file and field) it will simply get the field_current_value of the item's server DDO and set the value of the property grid item. Notes : Could be Broadcast as part of an initialise process Take care however. If the item has a combo form it MAY be that you DON'T want to set the value with the raw data but instead with a descriptive value. If this is the case, use Get DescriptionFromCode of the comboitem and set the value with this instead. ---------------------------------------------------
Set(Integer eType)
Inherited from cSigCJPropertyGridItem_Mixin
Set(Variant vValue)
Inherited from cSigCJPropertyGridItem_Mixin
Set(Variant vValue)
Inherited from cSigCJPropertyGridItem_Mixin
Set(Variant vValue)
Inherited from cSigCJPropertyGridItem_Mixin
--------------------------------------------------- Procedure : Set pvInitialValue Scope : Public Paramaters : Variant (vVal) Returns : None Purpose : Can be used to set both the value AND the default value (to be the same) at the same time Notes : If setting a value from event OnMoveItemDataIn then this is a useful way of setting both the value AND the default Otherwise, because the initial value is set during Private.OnCreate, any value applied afterwards will be seen to be different (the default will be the intial value - undefined) ---------------------------------------------------
Set(Variant vValue)
Inherited from cSigCJPropertyGridItem_Mixin
Set(Boolean bHidden)
Inherited from cSigCJPropertyGridItem_Mixin
Set(Boolean bReadOnly)
Inherited from cSigCJPropertyGridItem_Mixin
Set(Boolean bState)
Inherited from cSigCJPropertyGridItem_Mixin
Set(Boolean bState)
Inherited from cSigCJPropertyGridItem_Mixin
Set(Integer iWidth)
Inherited from cSigCJPropertyGridItem_Mixin
Set(Integer iColor)
Inherited from cSigCJPropertyGridItem_Mixin
Set(String sFormat)
Inherited from cSigCJPropertyGridItem_Mixin
Set(String llMask String llLiteral Variant llPrompt)
Inherited from cSigCJPropertyGridItem_Mixin
--------------------------------------------------- Procedure : Set PropertyItemMask Scope : Public Paramaters : llMask, llLiteral, llPrompt Returns : None Purpose : Sets the mask of a property grid item Notes : You can use any of these characters for defining your edit mask: 0 - Numeric (0-9) 9 - Numeric (0-9) or space (' ') # - Numeric (0-9) or space (' ') or ('+') or ('-') L - Alpha (a-Z) ? - Alpha (a-Z) or space (' ') a - Alpha numeric (0-9 and a-Z) a - Alpha numeric (0-9 and a-Z) or space (' ') & - All Print character only H - Hex digit (0-9 and a-F) X - Hex digit (0-9 and a-F) and space (' ') > - Forces characters to upper Case (a-Z) < - Forces characters to lower Case (a-z) llLiteral defines the prompt area of the mask where text entry is allowed. This should match the areas that you have already defined as mask fields. By default the prompt character is '_' . llPrompt is optional, but allows you to define default characters that you want displayed when the user presses the backspace key. This usually represents data that has been previously saved then restored. This makes it easy for the user to restore some or all of the default text displayed when the control was initialized. ---------------------------------------------------

References (55):

ModuleContaining SymbolLine
cSigCJPropertyGrid.pkgcSigCJPropertyGridSubCategory1607
cSigCJPropertyGrid.pkgcSigCJPropertyGridExpandBtnItem1862
cSigCJPropertyGrid.pkgcSigCJPropertyGridComboFormItem1946
cSigCJPropertyGrid.pkgcSigCJPropertyGridSpinFormItem2565
cSigCJPropertyGrid.pkgcSigCJPropertyGridSliderCtlItem2637
oCalendar_Properties.pkgoItem_Use_Icons19
oCalendar_Properties.pkgoItem_Use_Icons33
oCalendar_Properties.pkgoItem_Use_Icons47
oCalendar_Properties.pkgoCtgry_CaptionBar67
oCalendar_Properties.pkgoItem_ShowBar71
oCalendar_Properties.pkgoItem_Show_Date82
oCalendar_Properties.pkgoItem_Show_Date_Nav93
oCalendar_Properties.pkgoItem_Show_View_Nav104
oCalendar_Properties.pkgoItem_Reminders131
oCalendar_Properties.pkgoItem_Dialogs142
oCalendar_Properties.pkgoItem_Categories156
oCalendar_Properties.pkgoScaleTime_DayStart192
oCalendar_Properties.pkgoScaleTime_DayEnd206
oCalendar_Properties.pkgoScaleTime_Use220
oCalendar_Properties.pkgoItem_ToolTips262
oCalendar_Properties.pkgoItem_ClickToAdd276
oCalendar_Properties.pkgoItem_ClickToAddText290
oCalendar_Properties.pkgoItem_Minutes325
oCalendar_Properties.pkgoItem_IP_Create339
oCalendar_Properties.pkgoItem_IPE353
oCalendar_Properties.pkgoItem_IPE_Resize357
oCalendar_Properties.pkgoItem_IPE_F2371
oCalendar_Properties.pkgoItem_IPE_Mouse385
oCalendar_Properties.pkgoItem_IPE_Tab399
oCalendar_Properties.pkgoItem_Compress438
oCalendar_Properties.pkgoItem_OutlookGlyphs452
oCalendar_Properties.pkgoItem_WorkDayStart515
oCalendar_Properties.pkgoItem_WorkDayEnd529
oCalendar_Properties.pkgoItem_ShortLastDay543
oCalendar_Properties.pkgoItem_LastDayEnd557
oCalendar_Properties.pkgoItem_ShadeLunch571
oCalendar_Properties.pkgoItem_LunchStart585
oCalendar_Properties.pkgoItem_LunchEnd599
oCalendar_Properties.pkgoItem_Title624
oPropertyGrid_Container.pkgoItem_Name38
oPropertyGrid_Container.pkgoItem_Address145
oPropertyGrid_Container.pkgoItem_Address249
oPropertyGrid_Container.pkgoItem_Address353
oPropertyGrid_Container.pkgoItem_Address457
oPropertyGrid_Container.pkgoItem_Postcode61
oPropertyGrid_Container.pkgoItem_Telephone82
oPropertyGrid_Container.pkgoItem_SystemDate90
oPropertyGrid_Container.pkgoItem_Allow_Amend_Date94
oPropertyGrid_Container.pkgoItem_Default_Price133
oPropertyGrid_Container.pkgoItem_Admin_Password137
oPropertyGrid_Container.pkgoItem_Size142
oPropertyGrid_Container.pkgoItem_Height200
oPropertyGrid_Container.pkgoItem_Width209
oPropertyGrid_Container.pkgoItem_Customer_No219
oPropertyGrid_Container.pkgoItem_Order_No224