Previous Thread

7/31/2006 1:41:26 PM    LAN Replication
I have been reading and trying some code I have found here by David. 
 
Private Sub btnSynchronize_Click() 
 
Dim dbSource As DAO.Database 
 
Dim strDestinationMDB As String 
 
MsgBox "Make sure you are connected to the network. Press 'Ok' when ready.", 
 
vbOKOnly, "Synchronization" 
 
Set dbSource = DBEngine.OpenDatabase("C:\GasOpsDB\database\Replica of 
 
customer_be.mdb") 
 
dbSource.Synchronize "F:\GasOpsDB\database\Replica of customer_be.mdb" 
 
dbSource.Close 
 
Set dbSource = Nothing 
 
End Sub 
 
I thought this worked one time but now it keeps erroring out saying 'user 
 
defined type not defined' on "Dim dbSource As DAO.Database" 
 
I know very little about this and I have been learning as I have been going. 
 
Why is this happening? 
 
Gerald 
 
-- 
 
Message posted via AccessMonster.com 
 
http://www.accessmonster.com/Uwe/Forums.aspx/access-replication/200607/1



7/31/2006 5:51:34 PM    Re: LAN Replication
"gjameson via AccessMonster.com" <u21717@uwe> wrote in 
 
news:64121396f1169@uwe: 
 
You found your answer, but for the benefit of anyone who finds this 
 
thread in Google in the future, please follow up and tell what you 
 
find (and perhaps refer to the thread that helped you). 
 
Of course, the answer is a references problem, but since you were 
 
the one who had the problem, it might be more helpful to others who 
 
encounter the problem in the future to hear the explanation of the 
 
solution in the words of someone for whom all of this is new. 
 
-- 
 
David W. Fenton                  http://www.dfenton.com/ 
 
usenet at dfenton dot com    http://www.dfenton.com/DFA/

7/31/2006 7:03:18 PM    Re: LAN Replication
Nevermind, found my answer in another thread. 
 
gjameson wrote: 
 
-- 
 
Message posted via AccessMonster.com 
 
http://www.accessmonster.com/Uwe/Forums.aspx/access-replication/200607/1

8/1/2006 1:38:05 AM    Re: LAN Replication
You are right David. Sorry about that. I hhave learned so much from this 
 
board. the problem was that I did not has the DAO object referenced so access 
 
did not know what to do with that line. This was set in the VBA section under 
 
Tools\Reference. 
 
Gerald 
 
David W. Fenton wrote: 
 
-- 
 
Message posted via AccessMonster.com 
 
http://www.accessmonster.com/Uwe/Forums.aspx/access-replication/200607/1