Auto Save with No Luck

  • Hi,


    I have programmed one of my spreadsheets to Autosend in Outlook to a specific Address when I close the spreadsheet. Now what I would also like is to auto save as well. I can add code to save to a specific directory, but I would like the browse window to open so I could save to a certain dir. Kind of like using the saveas option in the file menu. I know it's easy to just go File/Save As, but this is a spreadsheet that I have designed for multiple users, (65 in Total) and to avoid any screw ups, I would like to add the autosave when closing the timesheet. Can anyone tell me how to get the save as browse window to open?


    Thank You

  • Hi


    You can use the following code to open the SaveAs dialog:

    Code
    Sub test()
        Dim b As Boolean
        b = Application.Dialogs(xlDialogSaveAs).Show("test.xls")
    End Sub


    The function returns TRUE if succesful, FALSE if the user canceled the save.


    Also, check out the Built-In Dialog Box Argument Lists in the help file for more information on the various arguments.


    HTH
    /Fredrik

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!