I have built my app using VB6 and it runs from a usb thumbdrive. I use a coded connection to my db as follows
What this provides is basically wherever my app runs, so long as the db is in the same folder it can find and use it. However, when I come to print the datareport I get errors. (I believe it's a 713?)Code:cn.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & App.Path & "\stock.mdb"
What I would like to know is, can this type of connection be used in the data environment which currently connects to the db like this
This will only print the datareport if the db is on the F:\stock drive folder. It needs to be dynamic as not every computer will make the app folder F.Code:Provider=Microsoft.Jet.OLEDB.4.0;Data Source=F:\stock\stock.mdb;Persist Security Info=False
I have tried substituting the code but it doesn't seem to want to know.
Any ideas greatly appreciated.




Reply With Quote