Difference between revisions of "Addproperty Method"
From Lianjapedia
Helen.george (Talk | contribs) |
|||
Line 8: | Line 8: | ||
==Arguments== | ==Arguments== | ||
− | {|class="wikitable" | + | {|class="wikitable"width=100% |
− | !Argument||Type||Description | + | !width=20%|Argument||Type||width=70%|Description |
|- | |- | ||
|cProperty||C||Name of the new property | |cProperty||C||Name of the new property |
Revision as of 11:51, 17 January 2013
Adds a property to the object.
ob.addproperty(cProperty, Value)
Arguments
Argument | Type | Description |
---|---|---|
cProperty | C | Name of the new property |
Value | Any | Value of the new property |
Example
// // Lianja custom section for page "page1" section "section1" // namespace custom1 public textbox1 define class page1_section1 as section enddefine define class info_button as CommandButton proc click Messagebox("Textbox created by " + textbox1.createdby; + " at " + textbox1.created,0,"Info") endproc enddefine proc page1_section1 page1_section1 = createobject("page1_section1") page1_section1.addobject("infobutton","info_button") infobutton.caption = "Information about Textbox 1" page1_section1.addobject("textbox1", "Textbox") textbox1.text = "Textbox 1" textbox1.addproperty("createdby",user()) textbox1.addproperty("created",time()) return page1_section1