+ Reply to Thread
Results 1 to 7 of 7

error 76 path not found

  1. #1
    Registered User
    Join Date
    03-19-2009
    Location
    tampa,fl
    MS-Off Ver
    Excel 2003
    Posts
    14

    error 76 path not found

    Hi,

    I an trying to write a macro to copy the last row from one workboo1 and paste it in workbook2. After pasting it needs to rename the second workbook in a new folder.
    Folling is the code.I am experiencing some problems like.
    error 76 Path not found.
    When i am trying to create a new folder.First i need to check if that folder exists or not.if it does it needs to save this workbook2 in that folder,otherwise create the new folder with that name and then save it.
    Please help.





    Please Login or Register  to view this content.

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: error 76 path not found

    keep your code tidy, declare all variables before the actual code. Also, you haven't declared all your variables.

    You shouldn; need to activate the workbooks.

    Depending on the format of Mydate you might not get a correct file name. Although in your code Mydate is a Row number!

    This is untested
    Please Login or Register  to view this content.
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Registered User
    Join Date
    03-19-2009
    Location
    tampa,fl
    MS-Off Ver
    Excel 2003
    Posts
    14

    Re: error 76 path not found

    Thanks royuk.

    I tried ur code and made it organised. But i still get the error 76 path not found. Please help.
    A little change in my task now.
    I dont want to create this new folder now but look for that folder which is already existing. If this folder is not existing then show a message box saying folder not found so create first and then generate this report.

    Please Login or Register  to view this content.
    Last edited by swe1; 03-30-2009 at 12:02 PM.

  4. #4
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: error 76 path not found

    What is GetDate returning, an example workbook would help.

  5. #5
    Registered User
    Join Date
    03-19-2009
    Location
    tampa,fl
    MS-Off Ver
    Excel 2003
    Posts
    14

    Re: error 76 path not found

    Get Date = 3/9/2009

    I am attaching both the workbooks.
    thanks for ur help.
    Attached Files Attached Files

  6. #6
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: error 76 path not found

    GetDate is returning an invalid format for naming a Folder. Try this
    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    03-19-2009
    Location
    tampa,fl
    MS-Off Ver
    Excel 2003
    Posts
    14

    Re: error 76 path not found

    Thanks RoyUK !
    It works.
    But i need to do little bit more to it now.
    The folder is already existing .So i just need to find that folder and save workbook2. And if the folder is not existing then a msgbox saying folder does not exists. Please Help.

    Please Login or Register  to view this content.
    End Sub

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1