Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to add object with procedure, programmatically in fo
Message
From
08/02/2000 14:46:20
 
 
To
08/02/2000 13:57:20
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00329025
Message ID:
00329079
Views:
24
1st question
holdrecsrc = grid1.recordsource
.grid1.recordsource = ''
.grid1.recordsource = holdrecsrc

2nd question
not sure. Is the line in your class definition caption = '' or caption = "?

>First Question
>If I put a checkbox in a grid and then set the recordsource to
> .grid1.recordsource = .grid1.recordsource
>the checkbox will dissappeared. Why and how to solve it???
>
>Second Question
>I want to put a checkbox in a column(grid) programmatically,
>e.g. : .grid1.column7.addobject('Check1','CHECKBOX')
>The problem with the above statement is it will add a basic vfp base class of checkbox. So I tried this statement:
>
> do program\definecheckbox.prg
> Check11 = CREATEOBJECT("Check1")
> thisform.grid1.column7.ADDOBJECT('chkSelect',Check11)
>
>but, as u know the third line give error...
>
> thisform.grid1.column7.ADDOBJECT('chkSelect',Check11)
>
>Check11 must be in single quote
>
> thisform.grid1.column7.ADDOBJECT('chkSelect','Check11')
>
>but, the above statement also have error...
>
> Class Definition Check11 is not found
>
>So, anyone can help???
>
>**************** definecheckbox.prg
>DEFINE CLASS Check1 AS CheckBox
>Caption = ''
>
>PROCEDURE InteractiveChange
>
>ENDDEFINE
>**********
--Todd Sherman
-Wake Up! Smell the Coffee!
Previous
Reply
Map
View

Click here to load this message in the networking platform