Modules & VBA :: Update Open Form After Linking To A New Backend Database

Mar 18, 2014

I have an Access DB with a form that allows the user to select a new backend database. I can connect to the backend and then .refreshlinks but nothing on the form is updated. I have tried requiring the form but that doesn't do anything. I've tried loads of other things, refresh, recalc etc., but nothing updates the open form.

The only way I have managed to get it to work is to close the form and reopen it, then it shows the data from the newly linked backend database.

While it works, it doesn't look good but also there seems to be some problem with it because eventually it reports an error saying "cannot open any more databases" and when clicking OK comes back with "An error occurred while sending data to the OLE server (the application used to create the object" and a whole bunch of other messages.

I think it might have something to do with the fact that the form has a number of MS graphs open on it, but I'm not sure. Also, I can't track down a particular line of VBA code which causes this error.

how to update a form after changing the backend database.

View Replies


ADVERTISEMENT

Linking To More Than One Backend Database

Nov 13, 2007

Hi - I have a front end database that is linked to 2 backend databases. I'd like to add code so that after the splashscreen pops up it checks to see if the front end is linked. If not then asks the user to enter the path for the two backend databases. I need your HELP!!1

Bukaw

View 1 Replies View Related

Backend Database - Front End Application Linking Issue

Nov 25, 2007

Hello all,

I have a back end database that i cannot access at the moment. Is it possible to set the link of the tables for the front end application based on the location that the database will be even though i can't see that location now?

Thank you in advance.

View 1 Replies View Related

Securing Backend Like Webserver Database And Linking Via Odbc Or Roaming User Profile

Apr 29, 2006

On a webserver certian files are stored above the root directory. Therefor the user of the website can never access those files directly. But he is utlizing that file.

For example:
We use Hotmail to see our mails. but we never download the complete database.

So is there a method that we can secure the backend using roaming profiles or something else so the user has a link to the backend but cant directly access the backend.

View 2 Replies View Related

Modules & VBA :: Using Unbound Form On Front End Of Database To Populate Backend Tables

Apr 12, 2015

Is there any particular reason I would choose to use

DoCmd.RunSQL "insert into...

Versus

CurrentDb.Execute "insert into.... ??

I am using an unbound form on the front end of my database to populate the backend tables (multiple tables). Some forms only have a few fields, while other forms have about 15 fields with 3-4 tables updating.

I am okay using the DoCmn.RunSQL , but I keeping reading on the forum that others chose CurrentDB.Execute and it has me thinking.

My database is stored on a network drive with only on front end.

View 2 Replies View Related

Modules & VBA :: Force Disconnect From A Backend Database

Nov 17, 2014

I have a database stored out on a shared drive at my company that multiple users connect to via a front end application that they save on their own hard drives. Recently I have noticed that the back end database keeps getting opened exclusively which prevents other users from being able to access the back-end database. For the life of me I cannot figure out what about the front end opens the back end exclusively and cannot find any plausible solutions I thought I could develop something that could force close a back-end database or disconnect all users from it?

View 3 Replies View Related

Modules & VBA :: Split Database - Moving Table To Existing Backend

Apr 8, 2015

I have a client that is using a split database. I am working on an update to the program and need to transfer a table to the backend that has the correct structure and information included in it. My thoughts are to make a one time use program that transfers the table to the backend. I have seen DoCmd.TransferDatabase and DoCmd.CopyObject as possible ways to go.

View 10 Replies View Related

Modules & VBA :: Open One Database Form Another And Pass Variable To It

Feb 19, 2014

I have a button on my main db, that opens a second db using hte following code:

----------------------
'Dealing with external objects, use inline error trapping
On Error Resume Next
Dim appAccess As Object

Dim db As Database
Dim strAppPathName As String
Dim strAppName As String
Dim strTimesheetPathName As String

[Code] ....

This code works great to open the other db, and handles wheter the other db is already open or not, but I cant seem to pass the variable to the other db using the startup switch /cmd.

I suspect if I used the shell method it would pass the cmd , but I havnt found any way to test if the db is already open with the shell method.

How can I pass a variable to the other db when opening it using VBA?

View 10 Replies View Related

BackEnd Linking Problem...

May 27, 2007

This is a basic thing, i think.

How do I link the backend tables to the front end so it works everywhere?
I mean right know it says C:ewprojectackend.mdb how do i change that to newprojectackend.mdb ?

Regards,

View 12 Replies View Related

Modules & VBA :: Linking Back End Database With Password?

Apr 28, 2014

I have a Back end (with password) which resides in a netdrive while the front end is installed in each individual users desktop, the problem is, some of the users netdrive was mapped in a different way (different letters..some are J others are G). I'm looking for code that I can relink the database to the front end in runtime, I did try to look in the net but I can't find anything that I can put the password as parameter.

this sample code from Dev is good, but i got an error because the database requires a password.where i can put the password?

Code:

Function fRefreshLinks(NewDbName As String) As Boolean
Dim strMsg As String, collTbls As Collection
Dim i As Integer, strDBPath As String, strTbl As String
Dim dbCurr As Database, dbLink As Database
Dim tdfLocal As TableDef

[code].....

View 8 Replies View Related

Modules & VBA :: Linking External Tables To Current Database?

Mar 16, 2015

I was wondering if it was possible to link random external tables to the Active Database through VBA. I would like to run the code that would open up a dialog box that would let the user select the database as well as the tables within that database that the user can select to link to. I am able to select the database and but not able to select the actual tables. The tables will be random so I can't make a constant statement for a specific database.

View 1 Replies View Related

Modules & VBA :: Automatically Linking Database With ODBC Connection

Jun 26, 2015

I am looking to automate the process of linking my Access DB with an ODBC connection to an SQL DB with VBA (unless there's an easier way to do it?) - some sample code - if this is possible at all?

View 2 Replies View Related

Modules & VBA :: Open Database / Run A Query / Close Database

Aug 22, 2014

i have a database that runs updates from within itself.what i need is, this database to then open a another database run a update query, then close it.

View 4 Replies View Related

Modules & VBA :: Open Another Database With Password

Aug 26, 2014

I am trying to open a database with a password (I know the password) from another database however I cannot work out how to do it. I have been using this code to do this to open databases without passwords for a while.

I am using Access 2007.

Code:
Private Sub Command36_Click()
Const cstrClientFEPath = "G:Templates"
Const cstrFEFile = "db.accdb"
Dim intX As Integer 'Utility var

[Code] ....

View 3 Replies View Related

Modules & VBA :: Open Another Database With A Button?

Jan 24, 2014

I am using the following event code to open a database from another. Everything works fine but, I would like add a mxgbox letting the user know the database does not exists and to contact me for assistance.

Private Sub cmdOpenTime_Click()
Dim accapp As Access.Application
Set accapp = New Access.Application
accapp.OpenCurrentDatabase ("c:PILOT_ApplicationTIME.Accdb")
accapp.Visible = True
End Sub

View 5 Replies View Related

Modules & VBA :: Identify Users With Database Open

May 1, 2014

I'm wondering if there's any way to find out who has a database open.

I've saved the file as an ACCDE for the users and kept the ACCDB file as my working file. Whenever I make changes to the db I need to save a new ACCDE file on top of the existing one. In order to do that, I need to ensure no one has the db open. Half the time I need to track down 1 of 15 people to find out who it is that has it open so I can kick them out and save.

I don't have any login features, but could use the POD # that each cubicle has associated to their computer if Access allows that...

View 8 Replies View Related

Modules & VBA :: Open Access Database From Outlook

Jan 18, 2015

I use the below code to open an access database, but it opens for a second and then closes. When I run the same code from excel, it works OK.

Code:
Sub OpenDatabase1()
Dim LPath As String
Dim LCategoryID As Long

[code]....

View 6 Replies View Related

Retrieve Data From Backend - Update Combo Box From Recordset

Dec 12, 2011

I have written code to retrieve data from a back-end, that is then bound to a form (late binding forms).

From the retrieved record set I want to update a combo box using 1 field from the data in the record set, only showing unique records in the list.

View 5 Replies View Related

Modules & VBA :: Check If Database Is Open (Read Only Mode)

Jul 16, 2015

I would like to be able to check if a db is open and if it is to prevent the user from proceeding.

I use the Access 2013 Runtime. I can check if a db is open by trying to open Exclusively, using something like

Code: [URL] ....

But if the db is already open Not exclusively and I try to open it exclusively it does not raise an error and it allows the user to open the db in Read Only mode.

I would like to be able to prevent this, because careless and/or inexperienced users may open several instances of the db.

Of course, if the db is already open exclusively it does not allow you to open it exclusively another time.

View 5 Replies View Related

Modules & VBA :: Open Another Database And Send Variable Back

Apr 24, 2015

I have code that from DB1 opens DB2 and runs a Function in DB2.

The DB2 function produces a Boolean result that i am trying to get back to DB1 without success. Below is the script.

Sub Test22()
Dim AC As Object
Set AC = CreateObject("Access.Application")
rc = "K:ARSHRAutomation_ProjectsMikeFEDB2.accd b"
AC.OpenCurrentDatabase (rc)
AC.Visible = True
AC.Run "SendVariable"
End Sub

Because i am using AC.Run "SendVariable" i cant find a way to get the value of SendVariable!!

View 2 Replies View Related

Modules & VBA :: Creating A Batch File To Open Up Another Database

Mar 11, 2015

I want to create a batch file that will be used in a RunApp macro command to open up another database.

View 2 Replies View Related

Backend Database

Nov 2, 2007

I have been given the responsibility for a database that resides on a company network. The Database has been created by using Access 2000 in Windows XP. There are windows folders fro each team that needs use of the database and within these folders is a macro that loads the form for each team. There is a shortcut folder to the Admin Entrance point wher the actual database and tables_be are located. I have looked at both the properties of both these files and both are Access 2000 databases?

The Database called Database( not my choice of name ) contains all the forms, queries, reports,modules etc and the tables are linked to what seems to be the Admin Entrance point. Unfortunately I am unable to see the full link when using linked table manager. This I presume is the tables located in tables_be. The database table_be contains all the tables.

When trying to store the Autonumbering to the database after corruption using a solution kindly supplied by Pat Hartmann by taking a copy of both the database and table_be and working on these I successfully got the autonumbering working.

What do I need to do to successfully implemting these on the network. I have tried to copy the new files back to the network with the same names and in the same location but am getting error messages when I try access some of the forms.

Unfortuately there is no documentation as to how this database has been constructed hence the long winded post.

View 1 Replies View Related

Modules & VBA :: Linking Popup Form To Main Form

Jan 23, 2015

I have a 'main' table with a Project_Number that links all the data in my db together. I have another table that uses that Project_Number as a lookup field to connect that tables data to the main data. I created a 'main' form that has the ability to enter data for the 'main' table. I want to be able to press a button and have the second tables form pop up and add that that specific Project_Number. I added the button and went through the wizard process. I then added the linking info through the builder. It works fine if there is already data entered for the project_number in that specific field. but if the field is empty, the popup window doesn't recognize a project_number and doesn't add it to that record. below is what I am using. The project_number in the 'main' table is text and the Project_Number in the 2nd table in a number since it is a lookup field.

Private Sub CongressionalDistrictCmd_Click()
On Error GoTo Err_CongressionalDistrictCmd_Click
Dim stDocName As String

[Code]....

View 9 Replies View Related

Closing A Backend Database

Jun 13, 2007

I have a front end and back end database

I have broken the links between the 2 databases



how can I close the backend database using VB from code in the front end database?

I keep getting errors that the DB is not exclusive

View 11 Replies View Related

Updating A Backend Database

Aug 21, 2006

A client has had a database in operation for about a year. They requested some updates. I have been trying to figure out an easy way to update table structer with out having the client go into the backend and add a field or two.

I wrote an update program, that copies the table from their backend, and copied it to the updated table and tried to copy it back to thier backend, but since it is in a relationship, it won't let me.

Any suggestions?

View 2 Replies View Related

Closing A Backend Database

Jun 13, 2007

I have a front end and back end database

I have broken the links between the 2 databases



how can I close the backend database using VB from code in the front end database?

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved