Results 1 to 5 of 5
  1. #1
    2 Star Lounger
    Join Date
    Aug 2005
    Posts
    132
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Path in network (Access 2000)

    I meet problems with copying databases throug the windows network.If i copy a database
    within my computer than it is OK. i can copy it.For example :
    strSource = "C:BEOM.mdb"
    strDest = "C:BEPilotCopyOM.mdb"
    FileCopy strSource, strDest

    However, if i change the destination and want to copy the dataase to the next computer
    withing the network, called "Valia", then i receive a an error "Error in file/path"

    The path to this computer is shown as follows:

    ValiacBEPilot
    However, if i try to put this path withing the StrDest line, then i get the error message:
    strDest = "ValiaC:BEPilotCopyOM.mdb"
    Obviusly the above line is wrong.May be i must add or remove something from this line.

    Can you help me to find the error in my line StrDest shown above?

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Path in network (Access 2000)

    You obviously shouldn't have C: in the network path - C: is a local drive. Is BE a share on Valia? If so, you can use "ValiaBE..."

  3. #3
    2 Star Lounger
    Join Date
    Aug 2005
    Posts
    132
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Path in network (Access 2000)

    Dear Hans,

    I want to thank you for your replies to both my threads. I am late with my thanks since i am still labouring
    under this problem.
    I have come accross a quite misterious behaviour and the only way to get some help from you is to explain in
    more details what happens.


    So, my target is to send the zipped form of the database BE.mdb formated with date,
    according to the rules of Winzip9, to the folowing address:

    ValiaC:BEArchiveBEBE


    The above line means that the neighbouring computer is called Valia, and in the folder C there is a subfoder BE and a subfolder ArchiveBE.


    Now when i perform the line

    Shell """C:Program FilesWinZipWZzip.exe"" ValiaC:BEArchiveBEBE" & Format(Date, "yyyymmdd") & " C:BEBE.mdb"

    nothing happens. I get no error, but the folder remains empty.

    What is mistery to me, is that when i perform the same code but withing my computer, then the file appears ! :

    Shell """C:Program FilesWinZipWZzip.exe"" C:BEArchiveBEBE" & Format(Date, "yyyymmdd") & " C:BEBE.mdb"

    The path in Valia is OK since the following code works and sends the file:


    Private Sub Command1_Click()
    Dim strSource As String
    Dim strDest As String
    strSource = "C:BEOM.mdb"
    strDest = "ValiaCBEArchiveBEOlaOM.mdb"
    FileCopy strSource, strDest
    End Sub


    But why with the right path name i cannot send the file to the other computer, but i can in my computer is a mystery to me.
    Is it possible that the reason is that the winzip 9 is not loaded on the other computer?

    Can you help ?

  4. #4
    WS Lounge VIP rory's Avatar
    Join Date
    Dec 2000
    Location
    Burwash, East Sussex, United Kingdom
    Posts
    6,280
    Thanks
    3
    Thanked 191 Times in 177 Posts

    Re: Path in network (Access 2000)

    Hi,
    In your Shell statement, you need to remove the colon between 'C' and 'BE' so it should read:
    ValiaCBEArchiveBEBE
    Regards,
    Rory

    Microsoft MVP - Excel

  5. #5
    2 Star Lounger
    Join Date
    Aug 2005
    Posts
    132
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Path in network (Access 2000)

    Thank to to you all !!!!!! I get the code working !!!!!!!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •