get values of dg

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: Klaus, FourthWorld, heatherlaine, kevinmiller

Post Reply
link76
Posts: 99
Joined: Fri Nov 04, 2011 1:52 pm

get values of dg

Post by link76 »

I want to save all values of my datagrid ​​in the database, how can I get the values ​​in array ?

thanks

Code: Select all

repeat with theLineNo = 1 to the dgNumberOfLines of group "Datagrid 1"
... get all value in array 
end repeat
dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10508
Joined: Wed May 06, 2009 2:28 pm

Re: get values of dg

Post by dunbarx »

Hi..

The dgData of group "yourDataGrid" returns this.

In the clear (not an array, but rather in an ordinary variable that is tab and return delimited) "the dgText" is what is used.

Craig Newman
snm
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 253
Joined: Fri Dec 09, 2011 11:17 am

Re: get values of dg

Post by snm »

Or dgData[colName] as an array if you prefer it. "i" is the rów number in DG.

Marek
dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10508
Joined: Wed May 06, 2009 2:28 pm

Re: get values of dg

Post by dunbarx »

Link76

You should download the datagrid user manual:

http://lessons.runrev.com/m/datagrid

Craig Newman
Post Reply