Save a File to a Specific location Using a Macro in Excel

Поделиться
HTML-код
  • Опубликовано: 13 окт 2024
  • Save a File Using a Macro in Excel, Save a file to a particular location using a macro. Save a file as a particular type using a macro. Check out my online courses www.easyexcelan...
    Become an Affiliate and earn 25% on Course Sales
    barb-s-school-...
    For more help visit my website www.easyexcelan... or email me at easyexcelanswers@gmail.com.
    code
    Private Sub CommandButton1_Click()
    Dim path As String
    Dim filename1 As String
    path = "C:\Users\Barb\Desktop\demo\"
    filename1 = Range("C4")
    Application.DisplayAlerts = False
    ActiveWorkbook.SaveAs Filename:=path & filename1 & ".xlsx", FileFormat:=xlOpenXMLWorkbookFileFormat:=xlOpenXMLWorkbook
    FileFormat:=xlOpenXMLWorkbook
    Application.DisplayAlerts = True
    Activeworkbook.close
    End Sub
    For more help visit my website www.easyexcelan... or email me at easyexcelanswers@gmail.com.
    Contact me regarding customizing this template for your needs.
    Excel one-on-one on-line training available. Email me to arrange.
    I am able to provide online help on your computer at a reasonable rate.
    www.amazon.com...
    Check out my next one-hour Excel Webinar
    www.crowdcast....
    I use a Blue condensor Microphone to record my videos, here is the link
    amzn.to/37gyyGa
    Check out Crowdcast for creating your webinars
    app.linkmink.c...
    If you need to buy Office 2019 follow
    amzn.to/2VX5dv8
    I use Tube Buddy to help promote my videos
    Check them out
    www.Tubebuddy....
    Follow me on Facebook
    / easyexcel.answers
    TWEET THIS VIDEO • Save a File to a Speci...
    Follow me on twitter
    easyexcelanswers
    IG @barbhendersonconsulting
    You can help and generate a translation to you own language
    www.youtube.com...
    *this description may contain affiliate links. When you click them, I may receive a small commission at no extra cost to you. I only recommend products and services that I've used or have experience with.

Комментарии • 218

  • @thres34
    @thres34 6 лет назад +4

    You deserve a place in heaven , many thanks for you video

  • @knotdavewalker
    @knotdavewalker 2 года назад

    The information I need for a file name is in 2 cells, name and invoice number, how do I put the 2 cell ranges together for a file name? Good video very clear. Thank you

  • @RicardoFlores_Senior
    @RicardoFlores_Senior 5 лет назад

    Excellent instructive video! I followed the steps and I got the Save button working in a matter of minutes. Thank you.

  • @ivanpap634
    @ivanpap634 4 года назад +3

    Really helpful and interesting! Is it possible to save in 2 differents path according to a specific cell value (path1 or path2)?

  • @firstgatebusinessservicequ6381
    @firstgatebusinessservicequ6381 3 года назад

    Very useful thanks. When I use this code it's work properly. but my saved macro file macros is not working. what kind of changes need to that. Kindly replay as soon as possible.

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  3 года назад

      when you save a file with a macro in it, the file extension changes to .xlsm If you save it as a .xlsx the macro will be lost

  • @AKaushal49
    @AKaushal49 4 года назад

    Hello Barb
    Video is really helpful..thanks for sharing it.
    Can you please share the code if the file in the designated path is already there...how to display the option to save it again with different name???
    Pls help me with this.
    Thanks

  • @govindchoudhari8629
    @govindchoudhari8629 3 года назад

    That's great...
    It works perfectly but the only thing is I also want to break all the links after save as the file. Is it possible ?

  • @salserokorsou
    @salserokorsou 4 года назад

    Thank You lady!!!
    This is the one I've been looking for!

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  4 года назад +1

      Glad it was helpful!

    • @salserokorsou
      @salserokorsou 4 года назад

      @@BarbHendersonconsulting do you have a one click macro how to save as PDF somewhere laying around maybe? 👀😁

  • @cambaz1000
    @cambaz1000 4 года назад

    Thanks a lot Barbara for this video. I used it. perfect lob.

  • @arthurparas2911
    @arthurparas2911 2 года назад

    Hey Barb great video thank you so much, is there any way to have the save as file name from two cells instead of one?

  • @jonnyjbrown87
    @jonnyjbrown87 3 года назад

    You've made my year. Thank you!

  • @alanjmcgibbon
    @alanjmcgibbon 5 лет назад +1

    I really like how straightforward this is. So much so that I’ve subscribed for more. However I have a problem with the macro. When I run it I finish up with a line highlighted in yellow. The line in question starts “ActiveWorkbook.SaveAs” and the message on screen is “Run-time error ‘1004’ Method ‘SaveAs’ of object ‘_Workbook’ failed. I am using Excel 2016. Can I please have a solution as the macro is perfect for the sheet I’m preparing.

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  5 лет назад

      on your path check that you have a closing "\" That is the normal cause of this error

    • @alanjmcgibbon
      @alanjmcgibbon 5 лет назад

      Thank you for the quick response. I placed the back slash at the end of the line after the expression “FileFormat:=xlOpenXMLWorkbook”and upon debugging I receive the message “Compile Error: Syntax error”. Have I put it in the wrong place?

    • @alanjmcgibbon
      @alanjmcgibbon 5 лет назад

      Sorry I misread your reply. I do have a back slash at the end of the line beginning path =

    • @kylegurney8610
      @kylegurney8610 Год назад

      @@alanjmcgibbon did you end up figureing this out? I have the same problem

  • @lukemartin7029
    @lukemartin7029 4 года назад

    Are you able to export an Excel sheet to save as a XML file via macro?
    I have a macro for copying and pasting data from one sheet into another sheet where I have columns that are XML Sourced set up how an application I'm using will accept them. I currently run the macro to copy and paste one batch of records at a time into the sheet then have to hit Export and name the files (1, 2, 3 etc.). My macro removes the batch of entries and copies in the next set. If a macro could export and name the file the next number in sequence that would be great.

  • @dhirendranathmandal6949
    @dhirendranathmandal6949 2 года назад

    Please make a video for VBA to Save a specific Excel sheet using data from cells & single click

  • @doomandgooner
    @doomandgooner 2 года назад

    Thankyou this is really helpful but what if I wanted the file format to be csv?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  2 года назад

      I am not sure, have never tried CSV

    • @graywolfweb1361
      @graywolfweb1361 2 года назад

      Hello. I believe you just replace
      ActiveWorkbook.SaveAs Filename:=path & filename1 & ".xlsx", FileFormat:=xlOpenXMLWorkbook
      with
      ActiveWorkbook.SaveAs Filename:=path & filename1 & ".csv", FileFormat:=xlCSV

  • @9986915565
    @9986915565 4 года назад

    I need your guidance here to copy the latest file in a folder and paste it in another path. Can you please help me on this..

  • @jeevab9273
    @jeevab9273 5 лет назад

    Great work barb your videos are awesome
    I have doubt in the code line active workbook saveas file name
    So here my doubts if its possible how we can save in PDF format or any other format
    Is there any changes in the code???

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  5 лет назад

      ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, filename:= _
      path + filename, _
      Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas _
      :=False, OpenAfterPublish:=False

  • @brodyharrison6029
    @brodyharrison6029 2 года назад

    Thank you! The key for me was adding the .txt after the file name.

  • @mf-wg1qi
    @mf-wg1qi 4 года назад +1

    Just noticed that the coding in description section is missing the term ".Text" from line "filename1 = Range("C4")" and two extra pasted in text "FileFormat:=xlOpenXMLWorkbook"

  • @Fuzzball2410
    @Fuzzball2410 6 лет назад

    Great tutorial very helpful, I'm new to the world of Marcos in excel.
    I am trying to stream line my job by learning how to write amazing little programs like this and stop carry over mistakes.
    How would one write a code to do the same job essentially, but go one step further to populate information from the original document.
    Scenario, there is a "client registry" which has various bits of information regarding the client, and I need to execute a function to take those bits of information and populate them into a template sheet and save as a new file. let me know if you have any advice on this one or links to similar vids.

  • @ashwind3966
    @ashwind3966 4 года назад +1

    Hi Barb,
    I have used the same code as u mentioned, however the code / step for Saveas is getting debugged. Can you please advise why

  • @thairalazawy6835
    @thairalazawy6835 4 года назад

    thank you for the efforts it was very clear example

  • @paulasamson3191
    @paulasamson3191 6 лет назад

    Excellent - very clear instructions given at a good pace.

  • @ashlenm3971
    @ashlenm3971 5 лет назад

    Hi Barb,
    I’m able to convert an excel sheet, save it & email it. But, my issue is I don’t know how to send it to someone else for someone to input information, use the macro to send it back. It has my C drive on it. Is there a way to put in a drive that converts when someone else opens it?

  • @pvaldeben01
    @pvaldeben01 6 лет назад

    Worked for me. I gt stuck on the difference between xlsm and xlsx. But i'm all good now. Than you for creating this video.

  • @alisazahra9664
    @alisazahra9664 4 года назад

    Hi mam. I have a question.. how to save as workbook from another workbook.

  • @krishnajagadeesh6307
    @krishnajagadeesh6307 5 лет назад

    I am your subscriber I support your channel thank you

  • @mahmartins7602
    @mahmartins7602 4 года назад

    What if the paths are from a list that you need to loop from? Different files names into different paths that will loop from a list?

  • @Laxmanmane007
    @Laxmanmane007 5 лет назад

    Hi Barb just joined to your channel please also make video on power bi eagerly waiting for power bi series video

  • @paulcote4257
    @paulcote4257 2 года назад

    Barb:
    Excellent video. I noticed the date submitted was 2017, so I was wondering if there are any changes for the newer Excel for Microsoft 365. he reason I ask is that I have a file that I use at work that is set up almost exactly as you played out, except it saves the file to the desktop. Since we migrated to 365 and all our computers are set up to save to a personal One Drive which then mirrors the files to the cloud one drive for that user. The problem now is the file still saves to the desktop in c:\desktop, so you don't see the files on your real desktop. The path for this newer one is C:\Users\Users Name\OneDrive - Government of Ontario\Desktop
    I can't for the life of me find the proper syntax to change it over. Can you offer any suggestions? Thanks

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  2 года назад +1

      The only thing I can think of is to go into the folder where you would lik to save the file and select another file. Go to the home tab of the folder. In the clipboard section of the menu bar there is a "Copy Path" double click this and place it in the code. Replace the file name with the desired file name and do not forget the closing "\" Here is an example of the path I copied using this method "C:\Users\screa\Downloads\onlineStatement.pdf"

    • @paulcote4257
      @paulcote4257 2 года назад

      Thanks!! @@BarbHendersonconsulting

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  2 года назад

      @@paulcote4257 your welcome

  • @djsameero
    @djsameero Год назад

    Can we save the worksheet to SharePoint using Macro. I have a macro which sends out an email with the content of the sheet but I also want it to save a copy on Sharepoint site. Is that possible?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  Год назад

      You will be able to send to SharePoint but you will not be able to run on SharePoint

  • @mf-wg1qi
    @mf-wg1qi 6 лет назад

    Barb,
    Awesome videos. I tried using this information on a Trivia Night Score Sheet I created. Only issue I have is that a blank Excel window opens after the save and my original file closes. I'll send an email with more background information. Again, thanks for the very informative videos.

  • @jdouangpanya
    @jdouangpanya 5 лет назад

    Loved the video, it worked for me. I’ve been trying to figure another thing out. Is it possible to add conditions to a cell that determine what the save path is? For example, when you click “save file” as in your video. If I wanted a condition that sets a different path based on the value of a cell. Is that possible? For instance, if I wanted to sort out dated forms. If cell “D5” contained the words “mar”(for March) the save path goes to a “March” folder. If cell “D5” contained word “Jan” (for January) then the save path goes to a “January” folder.

  • @mohammadyawar1901
    @mohammadyawar1901 4 года назад

    Great. Thanks for making this video, very helpful. But I don't want to close the active workbook after saving the file. Can anyone please help me out?

  • @aniruddharaje229
    @aniruddharaje229 6 лет назад +1

    Thank you so much for uploading this video.. It helped me a lot...

  • @Rollotollo100
    @Rollotollo100 5 лет назад

    Hi. What do I need to change in this code that the original excel stays active? Right now it automatically opens the saved excel and I dont want it to become active. I mean if I want to continue editing the original excel file.

  • @waseemlimbaliya6196
    @waseemlimbaliya6196 4 года назад

    What if Madam !!!! if i want to save a file into sub folder of Active workbook path as pdf. I dont care where the file is being saved , the macro should save the file where the active workbook located and make subfolder. For example Macro Enabled Workbook is Saved into C:\My Folder\Vouchers.xlsm. Now i want to save a PDF file into C:\My Folder\Payment Voucher\Voucher_001.pdf without giving the address. just want to save where the activeworkbook is being saved. please madam guide me.

  • @ianwillson2576
    @ianwillson2576 2 года назад

    I tried copying this format, not on a new Invoice but a method statement. I got the XL sheet to save to a random file, but the file was called General and not the File name that I assigned to it. Any ideas what I have done wrong

  • @Galu97
    @Galu97 2 года назад

    Hello, how would you make a macro to request the user to attach an PDF document, and save that document with a different name in another folder for it's consult.

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  2 года назад

      that would be quite a bit different than this macro

    • @Galu97
      @Galu97 2 года назад

      @@BarbHendersonconsulting do you think you can help me please? At the momento I have only achieve to attach the document as an object. But that doesn't really work.

  • @mussatv7255
    @mussatv7255 4 года назад

    Excellent
    I have some issues kindly help me to resolve
    1: how can i save the new file without micro without micro button

  • @amarkardile7185
    @amarkardile7185 5 лет назад

    Madam how to capy sheet2 in specific folder and path with cells name using userform..??

  • @p2kc1
    @p2kc1 3 года назад

    Hi Barb
    Thank you again for streamlining information
    I need to do something similar I'm not sure if it is possible to do
    Saving a .docx file instead with a specified name (file name=cell value)
    A trillion thanks

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  3 года назад +1

      you should be able to but I have never tried it

    • @p2kc1
      @p2kc1 3 года назад

      @@BarbHendersonconsulting I figured it out, thank you barb

  • @tejaskadam4099
    @tejaskadam4099 2 года назад

    Hi Barb,
    Its perfectly working on my PC
    however error is showing when other users of my company try to use the same. it might be because of username because all of them having different usernames.
    is there any way to fix this, so all users can save the file at assigned path.

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  2 года назад

      Where are you saving the file? If it is on your drive then it will not work for other users but if it is on a shared network, it should work

  • @jaquelineassis2218
    @jaquelineassis2218 3 года назад

    Hi Barb! I've played with your teachings but I couldn't figure out a way to combine them. I'd like to have a master PO file that increases the number by 1 when I open it, then, after I input the data, I'd like to have a button to save the workbook to a specific location, then clear the contents of the master PO and have it ready for next time. Any way to do it?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  3 года назад +1

      The code to increase the number would be located on the worksheet.
      You would then have to write code to copy and save the worksheet to a specific location and once it is save you would have to clearcontents to the worksheet but the worksheet would have to closed and opened again to achieve a new number.

    • @jaquelineassis2218
      @jaquelineassis2218 3 года назад

      @@BarbHendersonconsulting Thank you! Makes sense.

  • @limitone9564
    @limitone9564 2 года назад

    what if I'm using an EXCEL Userform and I want to drag/drop a Word doc on the same location/folder that the EXCEL is on and rename the WORD as the name on the header of the Word? The drag/drop is working but I just don't know how to code to save the WORD and rename it as the name on the header of the Word. I need help pls.

  • @mohammadtahir1217
    @mohammadtahir1217 6 лет назад

    Bundle of thanks. It turn my hour work to minutes. thanks again

  • @krishnajagadeesh6307
    @krishnajagadeesh6307 5 лет назад

    Super madam very nice bt I need agine one more question how to automatically open file my friend send one excel file to email me download then use hear save to pdf button have me click the button automatically open this workbook location one ( pdf folder) open then inside this pdf file have when I delete this pdf Fila not possible this he how to make please explain madam

  • @jerrymerritt1367
    @jerrymerritt1367 5 лет назад

    I am having a hard time writing a save button macro for the data in a worksheet and saving it to different files based on the value in one cell. If the value changes it saves the data into another file. I have 23 different files the data could be saved to based on the value of that one cell.

  • @Mattjd07
    @Mattjd07 6 лет назад

    does this work with a multiple worksheet workbook?
    do you have to define which worksheet your using or is it associated with the command button ?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  6 лет назад

      to be safe I would specify the worksheet.

    • @MT4LYF
      @MT4LYF 5 лет назад

      Mat - i did mine on 5 sheets of a workbook and it saved the whole workbook

    • @BaStriker
      @BaStriker 5 лет назад

      @@BarbHendersonconsulting Please advise how to select a particular worksheet to save. Currently it's saving the whole workbook which has 4 sheets. I want it to save only a particular sheet.

  • @mansoork123
    @mansoork123 7 лет назад

    Dear Barb,
    Thanks for the macro video. I have a doubt regarding with file save location. This file showing error other user system saving . Because the file location given as my PC. How to solve?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  7 лет назад +1

      If you click on the address bar and copy the file location it always works for me.

  • @cajyfernandes6708
    @cajyfernandes6708 2 года назад

    Beautiful Thank you 🔥🔥🔥😎

  • @blairmacpherson1989
    @blairmacpherson1989 2 года назад

    Hi Barb, I’m having an issue with my macro and I’m getting the error “method ‘SaveAs’ of object’_workbook’ failed” when I debug it’s the ActiveWorkbook.SaveAs that is highlighted. Any ideas?

    • @blairmacpherson1989
      @blairmacpherson1989 2 года назад

      ActiveWorkbook.SaveAs Filename:=path & filename 1 & “.xlxs”, FileFormat:=xlOpenXMLworkbook

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  2 года назад

      did you place the final "/" on your path?

    • @blairmacpherson1989
      @blairmacpherson1989 2 года назад

      Hi Barb,
      My path reads as:
      Path= “s:\public\FOLDER\FOLDER\”

  • @tylercooper7975
    @tylercooper7975 6 лет назад

    Hi Barb,Thank you very much for your video! Could you help me trouble shoot?I have an Error called Run-time error '1004':Method 'SaveAs' of object '_Workbook' failI have gone over the code several times and have looked through other comments but couldn't find this. I included the "/" at the end of the file name.I appreciate your time,Tyler

  • @faizraut1516
    @faizraut1516 5 лет назад

    Thank you so much, it was easy to understand and implement

  • @saurabhd8247
    @saurabhd8247 6 лет назад

    Hi Barb, is there a way to save a file without any name parameter to a particular directory. I already have the filename but different each time.

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  6 лет назад

      I hope this is what you need, I have attached the video
      ruclips.net/video/GgTQRF7cf94/видео.html

  • @riteshmishra559
    @riteshmishra559 6 лет назад +1

    Love it!really very helpful👍thanx!

  • @adamhennessey1622
    @adamhennessey1622 7 лет назад

    i need your help!! the Save command macro works. that's the good part. the bad part is that each saved file overrides the other. we are going to use this to keep a daily report, and each report has to be looked at from time to time.

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  7 лет назад

      Adam,
      Try this
      filename1 =Range ("C4").text & Date
      This should add the date to your filename before the xlsx. This should keep them separate unless you save the same file on the same day
      Barb

  • @aasastephenson1538
    @aasastephenson1538 4 года назад

    Awesome breakdown! You should be a teacher! Nice video!😀

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  4 года назад

      I have taught software for many years. Check out my free webinar tomorrow. www.crowdcast.io/e/excel-beyond-the-basics

  • @MT4LYF
    @MT4LYF 5 лет назад

    thanks Barb. at the end after pressing button a blank screen appears. i see it in your vid as well. how can that be deleted along with hitting save button ?
    recent subscriber
    Tom

    • @sotirisvrassas7528
      @sotirisvrassas7528 5 лет назад

      I suppose you can totally delete at the end of the code: "Application.DisplayAlerts = True
      ActiveWorkbook.Close"

  • @markdeboer8696
    @markdeboer8696 Год назад

    I also can use this on a button?

  • @NetworthPlus
    @NetworthPlus 5 лет назад

    Hello I Wana make that path name dynamic is that possible? For example I want to save that file in different folders based on the path I enter in excel

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  5 лет назад

      Have you seen this video, I think it might be the answer ruclips.net/video/VbYvSALwejE/видео.html

  • @kamrulzoha9223
    @kamrulzoha9223 6 лет назад +1

    From long time I want to find the way how to save as file with a cell reference
    I mean
    I copy and paste the path in Sheet 2, R1C1
    And I want to save my Sheet 1 content as PDF.
    How I can make this ?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  6 лет назад +2

      I have a video for that ruclips.net/video/SvtfY_LqCtM/видео.html

    • @salserokorsou
      @salserokorsou 4 года назад

      @@BarbHendersonconsulting And just like that going through the comment I find the next one I need! :D

  • @joesmith5801
    @joesmith5801 6 лет назад

    AMAZING video. You earned a subscriber and a thumbs up.

  • @moodkn
    @moodkn Год назад

    Great Madam.. Thanks...!

  • @diyeimeno
    @diyeimeno 7 лет назад

    Barb hello!!
    I'm trying to use your macro but I have an error here:
    ActiveWorkbook.SaveAs Filename:=path & filename1 & ".xlsx", FileFormat:=xlOpenXMLWorkbook it's marker with yellow, can you please let me know what I'm doing wrong?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  7 лет назад

      Carlos, Same reply as below, I find if you click in the address bar and copy the file location it always works for me. If you email me at easyexcelanswers@gmail.com I will send you the file that I made the video with and you can work from that if you like.

  • @nocode659
    @nocode659 7 лет назад +1

    Hi barb,
    I have a issue. I am automating a webpage to download a document from it using a vba script. I can click the download option but upon clicking i get a pop below the window like, { open, save as and close}. Alt + S works fine for saving the document. Can you provide me a solution for how to go about it! I have tried using send keys but in vain

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  7 лет назад

      The only thing that I would suggest is "Application.DisplayAlerts = False" at the beginning and "Application.DisplayAlerts = True " at the end of the code. Good luck

    • @nocode659
      @nocode659 7 лет назад

      Thanks Barb
      Application.Sendkeys"(% s)",true
      Is this correct for saving a file? I am searching it in many forum, but cant find a solution

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  7 лет назад

      I have used previously for saving a large number of files, so that you do not get the prompt to save for each one

    • @nocode659
      @nocode659 7 лет назад

      Can you please share the code as to save it? Because i enter some 10 values in excel and for each value it has to download the document! If you can share as to how to proceed further. It would be really helpful
      Regards,
      nelzy

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  7 лет назад

      Private Sub CommandButton1_Click()
      Dim path As String
      Dim filename1 As String
      path = "C:\Users\Barb\Documents\excel\test saving xlsm\"
      filename1 = Range("D3")
      Application.DisplayAlerts = False
      ActiveWorkbook.SaveAs Filename:=path & filename1 & ".xlsm", FileFormat:=52, CreateBackup:=False
      Application.DisplayAlerts = True
      ActiveWorkbook.Close
      End Sub

  • @hasmawiah1927
    @hasmawiah1927 4 года назад

    its amazing mam.. i have a question, how to save as the sheet that we want, for example i want to save sheet 1 and sheet 6.. thaks mam, i really need your help

  • @cmlosaria
    @cmlosaria 3 года назад

    you deserve more subs!

  • @georgealoyce4849
    @georgealoyce4849 4 года назад

    Nice video but to bad when i close my excel and reopen the button disappears, help me

  • @I3asher
    @I3asher 6 лет назад

    Say I have a value in A1 called Test and I want it to create a folder called Test where it saves itself as Test.xlsx in the defined path, is there a possibility to do this? I've been trying to look for a way to accomplish this for like 3 days.

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  6 лет назад

      I have a video for that ruclips.net/video/uOEN5OipAsY/видео.html

    • @I3asher
      @I3asher 6 лет назад

      You're an absolute hero!
      My next step is to my sheet to save itself with a name from a cell inside the folder it just created. Currently it's save both the folder and the file in the same folder.

  • @nowfalbeary7821
    @nowfalbeary7821 7 лет назад

    Hi,
    Can U pls Help me..?? 1.I have Many Sheets In One Work Book. So, I want to Save A Range Instead Of Entire WorkBook. 2.After Saving The New Saved File Opens And The Old One Closes. Pls Help me.

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  7 лет назад

      Nowfal Beary
      I am away from my computer for a few days.
      I can look at your problem on Wednesday,
      Barb

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  7 лет назад

      What I would do is copy the range to a new file and save it and then delete the old file

  • @brendoncafferkey3816
    @brendoncafferkey3816 3 года назад

    How can I have the file revert to the original file after hitting the save button?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  3 года назад

      If you have saved the original file as some other name then you can always go back to it. But there is no "undo"

    • @brendoncafferkey3816
      @brendoncafferkey3816 3 года назад

      @@BarbHendersonconsulting I guess what I mean is after saving the file I would like the workbook to clear or reopen the original file

  • @mrinmoyhalder7293
    @mrinmoyhalder7293 6 лет назад

    I've made a folder in D drive & mentioned that folder's address in macro, but file is saving in C:\Document instead of this specified location.please help me

    • @rajeshmuthu9881
      @rajeshmuthu9881 5 лет назад

      Did u get solution for ts.. I m facing the same

  • @myawesomelife2023
    @myawesomelife2023 6 лет назад

    How can I change the naming convention. I don't want it to pickup from excel sheet. Please suggest

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  6 лет назад

      You could add a message box asking the user to enter a name

    • @myawesomelife2023
      @myawesomelife2023 6 лет назад

      Barb Henderson hey, this will not work for 2000 files which has different naming convention. Besides I am not good at macro. Do u have tutorial? I been to your website it was more of Excel. I really like the way I do. I want to learn to write VBA

  • @penulisbestari
    @penulisbestari 3 года назад

    Thank you so much

  • @RickyMendez5
    @RickyMendez5 4 года назад

    Hi Barb, How can I make it save to an FTP location?

  • @assadmk1095
    @assadmk1095 4 года назад

    thank you so much,it helped me alot...

  • @hrvojerozan8285
    @hrvojerozan8285 3 года назад

    which is the code for the word document?

  • @jkhair1770
    @jkhair1770 6 лет назад

    Hi Barb,
    I am getting error in below line
    ActiveWorkbook.SaveAs Filename:"path & filename1 & ".xlsx",

  • @kirankarthikeyan2694
    @kirankarthikeyan2694 4 года назад

    Thank you .

  • @pdkbuptcilegon2180
    @pdkbuptcilegon2180 4 года назад

    how to save as file with format macro... please

  • @rizwanluckyn
    @rizwanluckyn 5 лет назад

    Hi Madam i am facing this error filename1 = Range("F4:AJ4").Text , where is fault? please help me

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  5 лет назад

      This code is used to save one file name not a range of file names

    • @rizwanluckyn
      @rizwanluckyn 5 лет назад

      Thank you for prompt reply, so which code i have o type???

  • @rayhanrana6773
    @rayhanrana6773 5 лет назад

    i write ".xlsx", and get a error message .Anyone have any idea how i can solve it.Thanks in advance.

  • @nigelkheng
    @nigelkheng 6 лет назад

    When I hover over the button, it doesn’t turn over for me to click on it. It has the symbol that allows me to reshape

    • @sotirisvrassas7528
      @sotirisvrassas7528 5 лет назад

      You're still in "Design Mode", under "Developer" area. Press that button again to exit and you'll be fine. A lot of time since your comment, and I hope you've found the solution already. So perhaps useful to other viewers....

  • @arunkumarkm5295
    @arunkumarkm5295 6 лет назад

    Hi Barb,
    nice tutorial, and thanks for uploading this video, and i have a doubt for save invoice data to next sheet using macro, i.e i want to create invoice 10 invoices per day, i want to bake up the data to next sheet, below codes are am using but not working properly, i would like to request if you upload any video what am ask, kindly share the link to me
    Sub transfer()
    'Copy the data
    Sheets("Sheet2").Range("E22:M22").Copy
    'Activate the destination worksheet
    Sheets("SOA").Activate
    'Select the target range
    Range("E6").Select
    'Paste in the target destination
    ActiveSheet.Paste
    Application.CutCopyMode = False
    End Sub
    thanks,
    Arunkumar K.M

  • @BaudilioBarahonaTrochez
    @BaudilioBarahonaTrochez 2 года назад

    dEJEN DE PONER TITULOS EN ESPAÑOL Y EL VIDEO ESTA GRAVADO EN INGLES.

  • @AryanSingh-pq5hu
    @AryanSingh-pq5hu 4 года назад

    Thanks

  • @tisue
    @tisue 6 лет назад

    Thanks Barb!

  • @kamrulzoha9223
    @kamrulzoha9223 6 лет назад

    How to save as PDF file ??

  • @ValmisFilm
    @ValmisFilm 6 лет назад

    Guys - watch out! There is one bad thing with that - I made the script and when I tested it well - it closed the file I was maing the code and I lost the code, because the file it saves does not have the VBA codes... so yeah, watch out!

  • @ValmisFilm
    @ValmisFilm 6 лет назад

    Thanks! Very nice!

  • @Milton1963
    @Milton1963 2 года назад

    Thnak you

  • @freshmuzik7515
    @freshmuzik7515 3 года назад

    In a same way how to create a folder?

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  3 года назад +1

      No but I have a video for that ruclips.net/video/uOEN5OipAsY/видео.html

  • @JaskC700
    @JaskC700 Год назад

    Could not get this code to work today.

  • @wellingtonmoreira115
    @wellingtonmoreira115 3 года назад

    Tks!

  • @DiscoverTalent143
    @DiscoverTalent143 6 лет назад

    Can you pl share code

    • @BarbHendersonconsulting
      @BarbHendersonconsulting  6 лет назад

      Private Sub CommandButton1_Click()
      Dim path As String
      Dim filename1 As String
      path = "C:\Users\Barb\Desktop\demo\"
      filename1 = Range("C4")
      Application.DisplayAlerts = False
      ActiveWorkbook.SaveAs Filename:=path & filename1 & ".xlsx", FileFormat:=xlOpenXMLWorkbook
      Application.DisplayAlerts = True
      Activeworkbook.close
      End Sub

  • @nitinrao7637
    @nitinrao7637 4 года назад

    can you please copy paste this code

  • @lakilakisorong8204
    @lakilakisorong8204 5 лет назад

    what if I want to save it to onedrive?

  • @yohannesabate3924
    @yohannesabate3924 7 лет назад

    Thank you!!!

  • @yohannesabate3924
    @yohannesabate3924 7 лет назад

    Why saved As file lost all the Macro features?