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!

read from database and write data to file

Status
Not open for further replies.

shaygan

Programmer
Feb 19, 2005
12
DE
I read and type the data out from a Access database
Now I will to write this data to a file
Dim StringName
............

objCmd.CommandText = strQuery
Set objRS = objCmd.Execute
...........
//web browser output
………..
<td><%= objRS("name") %> </td>
...........
With write(objRS("name")) i cant write data to file.
how can I save this data after reading from the database
as a String (how save objRS("name") in StringName)????

StringName= :(
 
As long as you havent closed the recordset then you can simply use
Code:
StringName = objRS("name")
If you want to write this value to a file then you need to use the File Scripting Object, or FSO as it is commonly known. There are lots of example of how to use the FSO within this forum and the FAQ area - do a quick search and you'll get plenty of results.

Tony
_______________________________________________________________
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top