Welcome! Log In Create A New Profile

Advanced

getting a value from a tble using FOR EACH

Posted by Joel 
Joel
getting a value from a tble using FOR EACH
May 22, 2009 11:12PM
Hi -

Using WebDev - how do I get a value in a table column? Here is the code I have been using, Doesn't seem to work right...

HReset(DocUsers)
FOR EACH SELECTED ROW OF TABLE_List_Users
DocUsers.ActiveItem_b = 1
DocUsers.DocumentID_i4 = iNewDocID

//info(TABLE_List_Users.COL_UserID)

DocUsers.DocUsersID_i4 = TABLE_List_Users.COL_UserID
HAdd(DocUsers)
END

I figured that the row referenced by FOR EACH SELECTED is the row it's currently referencing so no extra pinning down of which row we're talking was necessary - I guess that's a wrong assumption!

Thanks!

J
Louis Verbraak
Re: getting a value from a tble using FOR EACH
May 25, 2009 09:06AM
Hello Joel,

I don't use WB but only WD. This should work there, if you want to use the SELECTED rows. If you need all the rows of the table you should use FOR EACH ROW.

HTH.
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: