Populate from a Table..?

K

Kent Johnson

Hi all,

I'm trying to give 180 sessionvariables a value from a table.
I have tried:

Dim MyObj As Object,intCnt As Integer, intTest As Integer
For intCnt = 0 To 180
MyObj = myDS.Tables(0).Rows(intCnt).Item("myField")
intTest = MyObj
Session(intCnt.ToString) = intTest
Next

What have I missed?

/Kent J.
 
S

Sergey Poberezovskiy

You missed .Value:

Session(intCnt.ToString) = myDS.Tables(0).Rows
(intCnt).Item("myField").Value
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top