Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Storing datalist DataItem in a variable

Status
Not open for further replies.

marcalo

Programmer
May 19, 2004
6
CO
Hi
I have a datalist in my page and inside I'm running a query which includes a value of the datalist.
in the datalist I print like this
<# Container.DataItem("CONS_USUARIO") %>

I need to save the previous line in a variable so I can use its value in the query.
I need something like this:
vcons_usuario = Container.DataItem("CONS_USUARIO")
so I can using in the query like this.
strSQL = "SELECT * FROM BAYTER_USUARIO WHERE CONS_USUARIO = " & vcons_usuario

This does not work.
Any siggestions?
Thanks in advance,
Sebastian

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top