将 VB 连接到 MySQL [英] Connecting VB to MySQL
本文介绍了将 VB 连接到 MySQL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想问一些关于如何将VB6连接到MYSQL的帮助?也请提供参考资料.
I would like to ask some help on how to connect VB6 to MYSQL? Please provide references as well.
非常感谢
推荐答案
Google 表示您可以使用 ADO 和 MySQL ODBC 驱动程序.
Google indicates you can use ADO and the MySQL ODBC drivers.
Dim strConnection$, conn As Connection
'Fill in the placeholders with your server details'
strConnection = "Driver={MySQL ODBC 3.51 Driver};Server=myServerAddress;" & _
"Database=myDataBase;User=myUsername;Password=myPassword;Option=3"
Set conn = New Connection
conn.Open strConnection
MySQL 的 ODBC 连接字符串来自此处.
ODBC connection string for MySQL from here.
警告:航空代码.我自己从来没有这样做过.
Warning: air code. I have never done this myself.
这篇关于将 VB 连接到 MySQL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文