Re: External .mdb inside Forms
From: Henry (Henry_at_discussions.microsoft.com)
Date: 12/17/04
- Next message: EMS: "Re: 1 Subform feeding into 2 tables"
- Previous message: Access rookie: "Re: Combo box concatenation of fields"
- In reply to: Dirk Goldgar: "Re: External .mdb inside Forms"
- Next in thread: Dirk Goldgar: "Re: External .mdb inside Forms"
- Reply: Dirk Goldgar: "Re: External .mdb inside Forms"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 17 Dec 2004 15:49:02 -0800
That jutst worked perfectly ! I even opened a form with external data that way.
(I knew, one day I will be force to play with sql syntax ;-)
Now, when closing the form, I want to write the selected record back to the
external .mdb like:
Private Sub Form_Close()
If Me.Dirty Then
DoCmd.RunSQL "UPDATE Employees.......
But how would I write a complete record ?
"Dirk Goldgar" wrote:
> "Henry" <Henry@discussions.microsoft.com> wrote in message
> news:E31EC62C-39B4-4980-A721-47DF60457916@microsoft.com
> > I would like to use the
> >
> > Set appAccess = CreateObject("Access.Application")
> > appAccess.OpenCurrentDatabase file, , pwd
> >
> > DAO method to view an external table inside a listbox and than open a
> > record in a form and manipulate the data.
> >
> > Of course I could just import the table, but for security I can't do
> > this, because this way you have unprotected access to passwd
> > protected .mdb files.
>
> You can set a form's recordsource or a combo box's rowsource to a SQL
> statement that selects data from an external MDB, specifying the
> database password. For example,
>
> SELECT * FROM SomeTable
> IN "" "MS Access;database=C:\Temp\SomeDB.mdb;pwd=foo";
>
> Note that this method can be used if the external database is secured
> using a database password, which is a much simpler form of security --
> and easier to crack -- than user-level (workgroup) security.
>
> Note also that, if you hard-code your password in a rowsource or
> recordsource, that password isn't going to stay secret very long. You
> may be able to encrypt the password in your local database, then decrypt
> it and build the record/rowsource on the fly for a *little* more
> security, but this is fundamentally insecure and I don't think there's
> anything you can do about it short of applying user-level security
> instead.
>
> --
> Dirk Goldgar, MS Access MVP
> www.datagnostics.com
>
> (please reply to the newsgroup)
>
>
>
- Next message: EMS: "Re: 1 Subform feeding into 2 tables"
- Previous message: Access rookie: "Re: Combo box concatenation of fields"
- In reply to: Dirk Goldgar: "Re: External .mdb inside Forms"
- Next in thread: Dirk Goldgar: "Re: External .mdb inside Forms"
- Reply: Dirk Goldgar: "Re: External .mdb inside Forms"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|