Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


how to connect database in an hta

 
Logged in as: Guest
arrSession:exec spGetSession 2,7,32737
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [General Forum] >> Other Programming/Scripting Languages >> how to connect database in an hta
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: [1]
Login
Message << Older Topic   Newer Topic >>
 how to connect database in an hta - 3/27/2006 5:32:26 PM   
  mravi_prakash

 

Posts: 15
Score: 0
Joined: 3/27/2006
Status: offline
strConnectionString = "Provider=sqloledb;Data Source=mysql;Initial Catalog=DB;Trusted_Connection=yes;"
Set objConn = CreateObject("ADODB.Connection")
Set objCommand = CreateObject("ADODB.Command")
Set rs = CreateObject("ADODB.Recordset")
objConn.Open strConnectionString
Query = "SELECT * FROM time"
rs.Open Query, objConn, 1
rs.MoveFirst
Do Until rs.EOF
msgbors)
Loop
rs.Close
objConn.Close

this is wht i typed .. but no out put came .. it just displayed me a text wht i typed ...
i want my database to be access from a MSQL which runs on the stand alone ..system ... (localhost)
in my data base i have used the MYSQL ODBC connection datasource name:mysql
mysql database :sample
table:sample.time;
time is the table
can u please help its urgent

_____________________________

m. Ravi Prakash
B.E computer science
software engineer
 
 
Post #: 1
 
 RE: how to connect database in an hta - 3/28/2006 2:29:28 AM   
  ebgreen


Posts: 4613
Score: 31
Joined: 7/12/2005
Status: offline
Do you have On Error Resume NExt somewhere in your script? If so, comment it out. Are you getting and error?

_____________________________

"... when you are good and crazy, oooh, oooh, oooh, the sky is the limit!" - The Tick
Goog places to start:http://www.visualbasicscript.com/m_24727/tm.htm
http://www.visualbasicscript.com/m_47117/tm.htm

(in reply to mravi_prakash)
 
 
Post #: 2
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [General Forum] >> Other Programming/Scripting Languages >> how to connect database in an hta Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts