+ Reply to Thread
Results 1 to 2 of 2

saving sheet as new workbook

  1. #1
    Nigel
    Guest

    saving sheet as new workbook

    Hi,
    i have managed to write this which works ok for mt sheet saving as workbook:

    Namer = ActiveSheet.Name
    Location = "C:\Documents and Settings\myname\Desktop\Invoices"
    yearly = Format(Date, "yy")
    Dater = Format(Date, "mmmm")
    Clienter = Range("B23").Value
    detailer = Range("B32").Value

    ActiveSheet.Copy
    ActiveWorkbook.SaveAs Location & "\" & Dater & " " & yearly & "\" & Namer &
    " " & Clienter & " " & detailer

    however, i need it to save in the month folder as specified on the onvoice
    date but currently it is taking the month of today and searching for that
    folder. Can i take the cell data , range("H14"), and format the value to
    month only to get the variable to search for the month only??

    thanks, Nigel


  2. #2
    Dave Peterson
    Guest

    Re: saving sheet as new workbook

    Is it Dater that's the problem?

    maybe you can use:

    Dater = Format(activesheet.range("h14").value, "mmmm")

    to get that month.

    Nigel wrote:
    >
    > Hi,
    > i have managed to write this which works ok for mt sheet saving as workbook:
    >
    > Namer = ActiveSheet.Name
    > Location = "C:\Documents and Settings\myname\Desktop\Invoices"
    > yearly = Format(Date, "yy")
    > Dater = Format(Date, "mmmm")
    > Clienter = Range("B23").Value
    > detailer = Range("B32").Value
    >
    > ActiveSheet.Copy
    > ActiveWorkbook.SaveAs Location & "\" & Dater & " " & yearly & "\" & Namer &
    > " " & Clienter & " " & detailer
    >
    > however, i need it to save in the month folder as specified on the onvoice
    > date but currently it is taking the month of today and searching for that
    > folder. Can i take the cell data , range("H14"), and format the value to
    > month only to get the variable to search for the month only??
    >
    > thanks, Nigel


    --

    Dave Peterson

+ 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