[data grid] How to get the dgText really empty?

Trevor DeVore lists at mangomultimedia.com
Fri Dec 17 07:47:44 CST 2010


On Fri, Dec 17, 2010 at 5:22 AM, André Bisseret
<andre.bisseret at wanadoo.fr>wrote:

> MY PROBLEM:
> If I set the dgText of each dataGrid of card 1 and card 2 to empty (by
> script) then,
> If I click on the button of card 3, I get the recapitulation as if the data
> grids of card 1 and 2 were still populated!
>
> I know that one gets a really empty data grid  if one sets the
> dgProp[columns] of the data grid as well as its dgText to empty. So that, it
> is necessary to set again the dgProp[columns].
>
> Is there a more simple way to get the dgText of a data grid really empty?
>

Are you specifically telling the dgText to return column names?

put the dgText[true] of group "DataGrid"

If so then you will always have at least one line that contains the column
names. Either check if more than one line exists or pass in false rather
than true.

put the dgText[false] of group "DataGrid"

-- 
Trevor DeVore
Blue Mango Learning Systems
ScreenSteps: http://www.screensteps.com
Releasable Revolution Resources for Developers:
http://revolution.bluemangolearning.com


More information about the use-livecode mailing list