|
-
Feb 8th, 2010, 06:32 PM
#1
Thread Starter
Addicted Member
Can I distribute code generated access database for free?
if i make an access database from scratch using vb6 code, can i distribute it with my application for free?
Code:
Dim objDBE, objADO
Const dbVersion10 = 1
Const dbVersion11 = 8
Const dbVersion20 = 16
Const dbVersion30 = 32
Const dbVersion40 = 64
Set objDBE = CreateObject("DAO.DBEngine.36")
objDBE.CreateDatabase App.Path & "\DragAndDrop1.mdb", ";LANGID=0x0409;CP=1252;COUNTRY=0", dbVersion40
Set objDBE = Nothing
Set objADO = CreateObject("ADODB.Connection")
objADO.Open ("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & App.Path & "\DragAndDrop1.mdb")
objADO.Execute ("Create Table retailer(EasyFindLetter text(10), stock number, product_description text(255), upc text(50), cs_qty text(100), retailer_stock_number text(255), retailer_price Currency)")
objADO.Close
Set objADO = Nothing
-
Feb 8th, 2010, 06:48 PM
#2
Re: Can I distribute code generated access database for free?
Yes, even if you create it in Access itself (as long as you own that)
Sometimes the Programmer
Sometimes the DBA
Mazz1
-
Feb 8th, 2010, 06:50 PM
#3
Re: Can I distribute code generated access database for free?
There are no restrictions on distributing MDB files containing your own data. If such a file had Access items in it such as Access Forms, Queries, etc. they might require MS Access in order to use them though.
Even an MDB you created using Access can be used.
BTW: You don't need to use DAO to create a new empty MDB. You can use ADOX for this instead.
-
Feb 8th, 2010, 07:47 PM
#4
Thread Starter
Addicted Member
Re: Can I distribute code generated access database for free?
i will just use the one i created in access then. saves me about 2 hours or more of re-making a bunch of tables with indexes.
Very Many Thanks.
-
Feb 8th, 2010, 11:41 PM
#5
Frenzied Member
Re: Can I distribute code generated access database for free?
However, since you are using the createobject to instantiate your database objects, your program may fall short on a users machine if they do not have the required libraries. To ensure that MDAC is packaged with your system and installed correctly, add a reference to ado/dao, compile, and use the PDW to create an install package. Then you can remove them, the references that is, recompile your exe and use the files in the *.lst to either create a new cab with your new exe or to make sure inno/windows installer has the right files.
Good Luck
Option Explicit should not be an Option!
-
Feb 9th, 2010, 04:56 AM
#6
Re: Can I distribute code generated access database for free?
Thread moved to 'Database Development' forum (the 'VB6' forum is only meant for questions which don't fit in more specific forums)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|