Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
Access
3rdpartyusrgrp
access
activexcontrol
adp.sqlserver
commandbarsui
conversion
dataaccess.pages
developers.toolkitode
devtoolkits
externaldata
forms
formscoding
gettingstarted
internet
interopoledde
macros
modulescoding
modulesdaovba
modulesdaovba.ado
multiuser
odbcclientsvr
queries
replication
reports
security
setupconfig
tablesdbdesign
  
 
date: Mon, 24 Sep 2007 17:02:01 -0700,    group: microsoft.public.access.replication        back       


AllowBypassKey PLUS   
Just to clarify... you can only disable/enable AllowBypassKey on the 
master... then when you sync it passes the setting to the replicas ...right? 

Is there anyway for a replica to change the setting to enable if it has been 
disabled on the Master? 

ALSO,
I have a menu bar with compact& repair, make backup and synchronize on it in 
the BE. If I hide the tables sync button is grayed out. Is there a routine I 
can run from a button on a form in the BE to sync so I can hide the db?

Thanks!
date: Mon, 24 Sep 2007 17:02:01 -0700   author:   lmv

Re: AllowBypassKey PLUS   
=?Utf-8?B?bG12?=  wrote in
news:A94D6C33-D0AB-4C87-B6CF-9D8C4941DA48@microsoft.com: 

> Just to clarify... you can only disable/enable AllowBypassKey on
> the master... then when you sync it passes the setting to the
> replicas ...right? 

I dunno. I've never had a need to disable it in a replica, since I
only disable it on front ends. 

> Is there anyway for a replica to change the setting to enable if
> it has been disabled on the Master? 

I don't know that this is a replicable property or not, since it can
be set in replicas other than the Design Master. That is, if you can
set it for any replica, it appears to be local, so I can't say if
replicas of a DM with the property set will inherit the property
(and any changes to that property). 

If you want to change the properties on a different database, just
use OpenDatabase. In another MDB: 

  Dim db As DAO.Database

  Set db = DBEngine(0)(0).OpenDatabase("MyOtherDatabase.mdb")
  db.Properties("AllowByPassKey") = True
  db.Close
  Set db = Nothing

Now, of course, the property has to already exist, but reading
between the lines, it sounds like you want to be able reactivate the
SHIFT key bypass when you are prevented from opening the database,
which means that the property has already been created and set. If
you *don't* know that, then you'll want to use the ChangeProperty
code found in the Access help (if you search for AllowBypassKey
you'll find the code). 

> ALSO,
> I have a menu bar with compact& repair, make backup and
> synchronize on it in the BE. If I hide the tables sync button is
> grayed out. Is there a routine I can run from a button on a form
> in the BE to sync so I can hide the db? 

Synching direct with another db is very easy. I've posted the code
here a bazillion times: 

  Dim db As DAO.Database

  Set db = DBEngine(0)(0).OpenDatabase("c:\MyReplica.mdb")
  db.Synchronize("c:\MyOtherReplica.mdb")
  db.Close
  Set db = Nothing

That will synchronize the two databases named in the code, and it
can be run from any MDB (or from a VBScript, for that matter). Put
that kind of code behind a command button and provide a UI to pick
which replicas to synch and it will work in any context. 

-- 
David W. Fenton                  http://www.dfenton.com/ 
usenet at dfenton dot com    http://www.dfenton.com/DFA/
date: Tue, 25 Sep 2007 19:12:16 -0500   author:   David W. Fenton lid

Re: AllowBypassKey PLUS   
Thanks... I have read many (not bazillions) of your posts and appreciate 
them. Sorry I missed the answer... sometimes after reading for days... it all 
becomes a blur and other times the answer jumps off the page.

I'll see if I can figure it out now from your direction.
Thanks again!

"David W. Fenton" wrote:

> =?Utf-8?B?bG12?=  wrote in
> news:A94D6C33-D0AB-4C87-B6CF-9D8C4941DA48@microsoft.com: 
> 
> > Just to clarify... you can only disable/enable AllowBypassKey on
> > the master... then when you sync it passes the setting to the
> > replicas ...right? 
> 
> I dunno. I've never had a need to disable it in a replica, since I
> only disable it on front ends. 
> 
> > Is there anyway for a replica to change the setting to enable if
> > it has been disabled on the Master? 
> 
> I don't know that this is a replicable property or not, since it can
> be set in replicas other than the Design Master. That is, if you can
> set it for any replica, it appears to be local, so I can't say if
> replicas of a DM with the property set will inherit the property
> (and any changes to that property). 
> 
> If you want to change the properties on a different database, just
> use OpenDatabase. In another MDB: 
> 
>   Dim db As DAO.Database
> 
>   Set db = DBEngine(0)(0).OpenDatabase("MyOtherDatabase.mdb")
>   db.Properties("AllowByPassKey") = True
>   db.Close
>   Set db = Nothing
> 
> Now, of course, the property has to already exist, but reading
> between the lines, it sounds like you want to be able reactivate the
> SHIFT key bypass when you are prevented from opening the database,
> which means that the property has already been created and set. If
> you *don't* know that, then you'll want to use the ChangeProperty
> code found in the Access help (if you search for AllowBypassKey
> you'll find the code). 
> 
> > ALSO,
> > I have a menu bar with compact& repair, make backup and
> > synchronize on it in the BE. If I hide the tables sync button is
> > grayed out. Is there a routine I can run from a button on a form
> > in the BE to sync so I can hide the db? 
> 
> Synching direct with another db is very easy. I've posted the code
> here a bazillion times: 
> 
>   Dim db As DAO.Database
> 
>   Set db = DBEngine(0)(0).OpenDatabase("c:\MyReplica.mdb")
>   db.Synchronize("c:\MyOtherReplica.mdb")
>   db.Close
>   Set db = Nothing
> 
> That will synchronize the two databases named in the code, and it
> can be run from any MDB (or from a VBScript, for that matter). Put
> that kind of code behind a command button and provide a UI to pick
> which replicas to synch and it will work in any context. 
> 
> -- 
> David W. Fenton                  http://www.dfenton.com/ 
> usenet at dfenton dot com    http://www.dfenton.com/DFA/
>
date: Tue, 25 Sep 2007 17:40:01 -0700   author:   lmv

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us