•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the Visual Basic 4 / 5 / 6 section within the Software Development category of DaniWeb, a massive community of 426,470 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,272 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our Visual Basic 4 / 5 / 6 advertiser: Programming Forums
Views: 9598 | Replies: 64 | Solved
![]() |
•
•
Join Date: Jul 2007
Posts: 71
Reputation:
Rep Power: 2
Solved Threads: 1
hi veena .
con.open statement worked.
"rs.Open Text1.Text, con, adOpenForwardOnly, adLockOptimistic"
what it does actually.reply
regards
suneel
con.open statement worked.
"rs.Open Text1.Text, con, adOpenForwardOnly, adLockOptimistic"
what it does actually.reply
regards
suneel
•
•
•
•
Hi Suneel,
if u r using ADO, then open Connection like this:
con.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & App.Path & ";Extended Properties=DBase IV"
u have to give Extended properties in connection string, and when it comes to .dbf or older Foxpro Versions of data, they dont have a single DB, u have to mention Folder path name.
Regards
Veena
•
•
Join Date: Jul 2007
Posts: 71
Reputation:
Rep Power: 2
Solved Threads: 1
hi veena
is it possible that text1.txt can contain CHECK_2045.pdf.
can i give the name of folder directly where CHECK_2045 is present.
CHECK_2045 is present in C:\Suneel_development\New Folder\record reading\CHECK_2045.pdf
may i write like this
"rs.Open CHECK_2045.pdf, con, adOpenForwardOnly, adLockOptimistic
it is giving object required error.
wt to do here
regards
suneel
is it possible that text1.txt can contain CHECK_2045.pdf.
can i give the name of folder directly where CHECK_2045 is present.
CHECK_2045 is present in C:\Suneel_development\New Folder\record reading\CHECK_2045.pdf
may i write like this
"rs.Open CHECK_2045.pdf, con, adOpenForwardOnly, adLockOptimistic
it is giving object required error.
wt to do here
regards
suneel
hi Suneel,
In the above Program, con is the Connection Object which allows u to connect to the Database. Since Database has many sets of tables, u will have to use RecordSet object to access data.
check this :
rs.Open "Select * from MyTable", con, adOpenForwardOnly, adLockOptimistic
here RS is the Recordset object which actuualy holds Table Data, this is opened thru Con object.
CHECK_2005 should be .dbf File and Is actually the Table and u r opening it thru recordset.
u cannot open PDF files with ADO in VB6
Regards
Veena
In the above Program, con is the Connection Object which allows u to connect to the Database. Since Database has many sets of tables, u will have to use RecordSet object to access data.
check this :
rs.Open "Select * from MyTable", con, adOpenForwardOnly, adLockOptimistic
here RS is the Recordset object which actuualy holds Table Data, this is opened thru Con object.
CHECK_2005 should be .dbf File and Is actually the Table and u r opening it thru recordset.
u cannot open PDF files with ADO in VB6
Regards
Veena
Hi,
Create Folder "MyDBF" in C
and place all dbfs's there in ("c:\MyDBF")
and use this code:
Yes, u can send me the project. I will modify and return back.
Regards
Veena
Create Folder "MyDBF" in C
and place all dbfs's there in ("c:\MyDBF")
and use this code:
con.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\MyDBF; Extended Properties=DBase IV" rs.Open "Select * from CHECK_2005", con, adOpenForwardOnly, adLockOptimistic
Yes, u can send me the project. I will modify and return back.
Regards
Veena
Last edited by QVeen72 : Jul 23rd, 2007 at 7:53 am.
•
•
Join Date: Jul 2007
Posts: 71
Reputation:
Rep Power: 2
Solved Threads: 1
hi i was waitin for ur reply but u went offline. hey how to send projct to u.may i have ur mail id where i can send it .
reply now
regards
suneel
reply now
regards
suneel
•
•
•
•
Hi,
Create Folder "MyDBF" in C
and place all dbfs's there in ("c:\MyDBF")
and use this code:
con.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\MyDBF; Extended Properties=DBase IV" rs.Open "Select * from CHECK_2005", con, adOpenForwardOnly, adLockOptimistic
Yes, u can send me the project. I will modify and return back.
Regards
Veena
•
•
Join Date: Jul 2007
Posts: 71
Reputation:
Rep Power: 2
Solved Threads: 1
ya i got ur pvt msg.
veena my gmail id is suneelkashmiri@gmail.com,rediff id is kar_suneel022@rediffmail.com
add me there .
modify the project and send it in my gmail id .
with regards
suneel kar
veena my gmail id is suneelkashmiri@gmail.com,rediff id is kar_suneel022@rediffmail.com
add me there .
modify the project and send it in my gmail id .
with regards
suneel kar
•
•
Join Date: Jul 2007
Location: Philippines
Posts: 205
Reputation:
Rep Power: 0
Solved Threads: 22
Hi Vee,
you know I'm confused, why we dont need to mention the dbf file but only their path?
the connection is now ok but there's still a problem on me here why I can't use it in a query? here's my code for that dbf.
Is there something I should add in my query?
The error is in here
you know I'm confused, why we dont need to mention the dbf file but only their path?
the connection is now ok but there's still a problem on me here why I can't use it in a query? here's my code for that dbf.
Set db = OpenDatabase(App.Path & "\", False, False, "dBase IV;")
Set Data1.Recordset = db.OpenRecordset("select * from color where clrcode='" & Text1.Text & "'")The error is in here
Set Data1.Recordset = db.OpenRecordset("select * from color where clrcode='" & Text1.Text & "'") Last edited by jireh : Jul 23rd, 2007 at 9:00 pm.
![]() |
•
•
•
•
•
•
•
•
DaniWeb Visual Basic 4 / 5 / 6 Marketplace
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
Similar Threads
- browsing file in VB? (Visual Basic 4 / 5 / 6)
- Reading or writing a double into a bin file (C++)
Other Threads in the Visual Basic 4 / 5 / 6 Forum
- Previous Thread: Spread sheet
- Next Thread: vb6-excel


Linear Mode