mullykid
asked on
Access Forms - Changing Shared Link Data Source
Hi,
I wish to distribute my access forms to customers who do not have MS Access, i.e. they will execute them via the run time library.
My forms contain links to SQL Server DB tables only. These links need to be changed per customer during configuration/installation . The table names will be the same, but the host name, DB user, DB name may not.
Please tell me this is possible! I can't find out how to it. Do I need to create a form to handle it?
TIA!
Iain
I wish to distribute my access forms to customers who do not have MS Access, i.e. they will execute them via the run time library.
My forms contain links to SQL Server DB tables only. These links need to be changed per customer during configuration/installation
Please tell me this is possible! I can't find out how to it. Do I need to create a form to handle it?
TIA!
Iain
ASKER
Thanks Peter.
When I run it inside access it works.
When I run it via the run time library though it crashes. Do you know why? This is where I need it to work.
When I run it inside access it works.
When I run it via the run time library though it crashes. Do you know why? This is where I need it to work.
ASKER
Hi,
It appears this is not a run time feature, and other code is required.
It appears this is not a run time feature, and other code is required.
Didn't realise this was regarded as a 'design' feature.
It's a lot of code then.
Here is a standard approach.
http://access.mvps.org/access/tables/tbl0010.htm
It's a lot of code then.
Here is a standard approach.
http://access.mvps.org/access/tables/tbl0010.htm
ASKER
Hi,
This appears to be for Oracle ODBC. Anything for SQL Server?
This appears to be for Oracle ODBC. Anything for SQL Server?
ASKER
Hi,
I think I may do this. Create a form so that the DBName, Server, user name and password etc. can be configured/entered by the user (at install time for example) and then store this data and update the connection string for each Link table.
Can you show me how I would update the connection string with such variables?
I think I may do this. Create a form so that the DBName, Server, user name and password etc. can be configured/entered by the user (at install time for example) and then store this data and update the connection string for each Link table.
Can you show me how I would update the connection string with such variables?
I just answered something very similar.
https://www.experts-exchange.com/questions/27381763/Looking-for-code-to-change-filepath-for-all-linked-tables-from-various-sources-for-multiple-databases.html?cid=1572&anchorAnswerId=36920121#a36920121
Have a look and post if you wind up in the weeds.
TEST with the run-time.
The run-time is designed to be unhappy with design changes.
What works full blown may not work run-time, so TEST in that environment
https://www.experts-exchange.com/questions/27381763/Looking-for-code-to-change-filepath-for-all-linked-tables-from-various-sources-for-multiple-databases.html?cid=1572&anchorAnswerId=36920121#a36920121
Have a look and post if you wind up in the weeds.
TEST with the run-time.
The run-time is designed to be unhappy with design changes.
What works full blown may not work run-time, so TEST in that environment
ASKER
Hey Nick. Thanks for your reply.
The link doesn't seem to work. It loads a blank page. Can you give me your suggestion?
The link doesn't seem to work. It loads a blank page. Can you give me your suggestion?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Dude, thanks a million. Finally a sensible way of doing this.
Private Sub Command0_Click()
DoCmd.RunCommand acCmdLinkedTableManager
End Sub