Results 1 to 2 of 2

Thread: Save As function for data exported to excel

  1. #1

    Thread Starter
    Member
    Join Date
    Mar 2013
    Posts
    33

    Save As function for data exported to excel

    After user input in my software i have a feature which exports all data to an existing excel file in which i have already formatted and given the report headings and everything which does not change. i dont want to give the user the burden to save it, it shud be saved automatically. that part is actually done, but the problem is the intellicent is not giving me an option to save it in a different path. it is over writing the template file. How do i go about doing this??


    Code:
     MyExcel.ActiveWorkbook.SaveAs(P1Scorer.Name + " VS " + P2Scorer.Name + ".xlsx")
    Its telling me to enter the filename and extention after which it asks for the fileformat which i want to be default and then its asking for password and other kind of stuff but how do i set the save as path?? so that it doesn overwrite my template.

  2. #2
    PowerPoster dunfiddlin's Avatar
    Join Date
    Jun 2012
    Posts
    8,245

    Re: Save As function for data exported to excel

    Um ... by not using P1Scorer.Name + " VS " + P2Scorer.Name + ".xlsx" as the filename? I really don't understand what the problem is here. You can save the file as many times and using as many different names as you want at any stage while the workbook is active/open.
    As the 6-dimensional mathematics professor said to the brain surgeon, "It ain't Rocket Science!"

    Reviews: "dunfiddlin likes his DataTables" - jmcilhinney

    Please be aware that whilst I will read private messages (one day!) I am unlikely to reply to anything that does not contain offers of cash, fame or marriage!

Posting Permissions

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



Click Here to Expand Forum to Full Width