Home All Groups Group Topic Archive Search About

Linking to tables in a secured database from an unsecured database

Author
6 Apr 2005 4:47 AM
Jenny
I'm trying to refresh the links to a secured database from an unsecured
database - the connect seems ok but the refreshlinks fails with a '3219
Invalid operation' message. The code to refresh is:
    tdf.Connect = ";DATABASE=" & StrPath & ";UID=eTimeIndo;PWD=XcnsDio79p"
    tdf.SourceTableName = StrTable
    On Error Resume Next
    DoCmd.DeleteObject acTable, StrTable
    db.TableDefs.Append tdf
    On Error GoTo LinkErr
    tdf.RefreshLink

What am I doing wrong?

Author
6 Apr 2005 4:55 AM
Paul Overway
First, you need to create a new Workspace object that uses the proper
workgroup file.  You also need to read up on the Connect property for
tabledefs, because what you're using isn't a proper value...it should just
be ";DATABASE=" & strPath.  After you've logged in to a secure Workspace,
then you should be able to set the Connect property and RefreshLink....the
other stuff you're doing is pointless.


--
Paul Overway
Logico Solutions
http://www.logico-solutions.com


Show quote
"Jenny" <Je***@discussions.microsoft.com> wrote in message
news:A93C08AF-194C-455E-9F51-A8F744DDA9B5@microsoft.com...
> I'm trying to refresh the links to a secured database from an unsecured
> database - the connect seems ok but the refreshlinks fails with a '3219
> Invalid operation' message. The code to refresh is:
>    tdf.Connect = ";DATABASE=" & StrPath & ";UID=eTimeIndo;PWD=XcnsDio79p"
>    tdf.SourceTableName = StrTable
>    On Error Resume Next
>    DoCmd.DeleteObject acTable, StrTable
>    db.TableDefs.Append tdf
>    On Error GoTo LinkErr
>    tdf.RefreshLink
>
> What am I doing wrong?
>
>

AddThis Social Bookmark Button