Save As Filename From Cell & In Specific Folder

Jan 10, 2007

I'm trying to use the code below to paste special my first sheet to remove the formulas, then delete all other worksheets then save as a reference number (which is linked to the worksheet im saving) but I also need it to save in a specific folder.

Sub SaveAsCell()
ActiveWorkbook.Save
Cells.Select
Selection.Copy
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False
Sheets("Cat Nos").Visible = True
Sheets("Supplier Info").Visible = True
Sheets("Codes").Visible = True
Sheets("Buyers").Visible = True.................................

View 3 Replies


ADVERTISEMENT

Macro To Save Copy That Uses Specific Filename?

Jun 6, 2013

I want a macro that will save a copy of the current file using specific naming convention. My file is called OTR2CMMASTER - I want the macro to save a copy as OTR2CMSAGE(CURRENTMONTH/YEAR). The OTR2 is a named field (ProjectCode) in the workbook.

View 5 Replies View Related

Macro To Save As To Specific Folder

Apr 29, 2014

Looking for VBA code to automatically save an excel file as an .xlsx format, and saving to a specific folder: C:UserswolfmDesktopLoad Lists

I have been using the attached code, but it's not working. It saves to the desktop, not the folder. Also, when it creates the file name based on sFile = ActiveSheet.Range("C4").Value & ".xlsx", it adds wierd things to the file name. I want the file name to be simply the value in C4.

View 2 Replies View Related

Save With Date In A Specific Folder

Jun 16, 2009

I have found out how I save my document as workbook name and date, but now I want to add the saved file to a specific folder instead of just in my dokument folder. This is what I have done so far (SAVING FILE IN A SPECIFIC FOLDER):

View 5 Replies View Related

Macro To Save A File To Specific Folder?

Dec 7, 2012

I have a folder called "Report" at C: and inside this folder there are 12 folder named from 1 to 12 ("1","2",...,"12")

I need a macro to save my workbook as a file in C:Report(one of these folders depending on the month of a certain cell)

i.e. if the date in this cell is 8/12/2012 .. then save my file in C:Report12*.xlsm

This is the code i use

Code:
Private Sub CommandButton1_Click()
Dim fname As String
fname = Format$(Range("S8"), "dd-mm-yyyy")
On Error Resume Next
ActiveWorkbook.SaveAs Filename:="C:Reort" & fname & ".xlsm"
End Sub

So what i need now is what to insert after C:Report

View 9 Replies View Related

Save Workbook With Current File Name To Specific Folder

Dec 4, 2007

I recorded a macro to save a workbook to a specific folder using the current file name. However, I've tried to remove the absolute reference to a specific filename but it is not working for me. Am I close?

ActiveWorkbook.SaveAs Filename:= _
"H:Files and DocumentsPROJECTSSR 2 SS Phase Two Component ReliabilityWinTrac Files xt_conversionsexcel_version" & SheetName _
, FileFormat:=xlOpenXMLWorkbook, CreateBackup:=False

View 2 Replies View Related

Lookup Folder From Cell Text Then Save Excel File In This Folder

May 14, 2014

I have alot of project folders on my harddrive.

All in format: I:/12345-costumer-projectname/

The five digits are unique for each project.

I make calculations for these projects using an excel file. In this excel I also type the projectnumber (cell J2)

Now i would like to make a button. When pressed, it checks the projectnumber cell J2, looksup the corresponding folder and saves the excelfile in PDF format in this folder.

I have found macro to find files in folders, but none which do the above.

View 4 Replies View Related

Creating A Folder And Saving In It With A Filename Taken From Cell

Mar 21, 2009

I would like excel to create the folder C:/Bill if it doesn't already exist when I click save/save as option and save the workbook in it with a filename that is a combination of text/values in cells A1 and A2 on Sheet1. Better if the save as dialog box appears with this option selected so that I have to just click Save in the save as dialog box to save it in "C:/Bill".

View 9 Replies View Related

Refer Folder/Filename In VBA Code Through Named Cell Reference

Oct 31, 2008

I have the following codes in which I am to refer a file and folder to do some further processes.

myfilename = "C:Documents and settingsacsMy DocumentsEntrymyfile1.xls"
folderPath = "C:Documents and settingsacsMy DocumentsEntry"

I want to enter these two paths in a sheet in my excel report file (For example, I am running the report from Report1.xls, in which there is a sheet name "Filepaths". In this,

in B5, I would like to enter the Filepath (B5 named as "FILEPATH")
in B6, I would like to enter the Folderpath (B6 named as "FOLDERPATH")

So that, if I am copying the folder to another area, I no need to change the code every time in the VBA editor. I can do changes in these cells and it will be taken as the path to run the code further.

View 2 Replies View Related

VBA To Print Active Sheet To PDF Auto Save In Specific Folder Then Mail Using Outlook

Jul 17, 2014

How do I write a vba code to print active sheet to pdf, auto save in specific folder then mail using outlook

im using 'Nitro PDF Creator'

also id like it to automatically save the pdf as the same file name as the active worksheet and also auto enter the following when opening the email server:-

Address: Cell D18
Subject: Cell D21
Email body:

find attached quotation

Optional installation available on request

View 2 Replies View Related

Create New Workbook And Save Filename From Cell Value

Nov 1, 2009

Im trying to create a macro that when i click the button a new workbook is created and saved as the value from C5 cell.

View 9 Replies View Related

Recording Macro To Save Workbook Using Filename In Cell?

Aug 5, 2013

I'm trying to record a macro that calls up the saveas dialogue and uses a filename from a cell (it's the w/c date). I can start recording the macro, open the dialogue box and copy the contents of the cell but i can't get it to paste as the filname.

What I'm trying to achieve is to allow users of a muli-sheet workbook to be able to click on a 'save' button on any sheet and have the workbook save with a filename which includes the current week commencing date. This way all the weeks changes will be in just one file and from the following monday a new file will be started the the old one left alone as an archive.

View 9 Replies View Related

Auto Generate Save As Filename From Multiple Cell Data?

Sep 14, 2012

way for my engineers to save a field ticket with a certain name based on data from a couple of cells in the worksheet. Re: Auto generate "Save As" filename from text and tried to use some code posted in the thread, but I an still not having any luck.

What I want to do is create an active X button when clicked on, would save the workbook to a certain folder. I want the name to look like this:

SO1!M3_SO1!M6_SO1!H2.xls

This is what I have so far:

Private Sub SaveMe()
ThisWorkbook.SaveAs Filename:="C:usersdefaultdesktop" & Range("SO1!M3").Value & Format(Range("SO1!M3").Value, "text") & ".xls"
End Sub

Would I click "general" or "workbook" in VBA when I enter this code?

View 5 Replies View Related

Increase Invoice Number And Save To Desktop As PDF Using Cell Data For Filename

May 15, 2014

Our business has a spreadsheet set up for invoicing. A Macro has been created to increase the invoice number, save to the desktop as a PDF with a file name taken from the cells

This is working on my colleagues mac but when we've loaded onto my computer it errors, when I debug I am getting the following error:

Sub Macro3()
'
' Macro3 Macro
'

'
Range("g10").Select
[g10] = [g10] + 1

[Code] .......

View 2 Replies View Related

Open Website - Download CSV File / Save As In Specific Folder Under Different Name And File Type

Jul 6, 2012

I am trying to open a website, then for excel to download the csv file, then for it to save it in a specific folder under a specific name and file format (excel).

I am successful at opening the website with the following code, but how to do the rest.

Sub Searchez()
Dim IE As Object
Set IE = CreateObject("InternetExplorer.Application")
IE.Navigate "http://quote.morningstar.ca/Quicktakes/stock/keyratios.aspx?t=clwr®ion=USA&culture=en-CA&ops=clear" 'load web page google.com
IE.Visible = True
While IE.Busy
DoEvents
Wend

'IE.Navigate2 "javascript:SRT_keystuts.exportcsv()"
'this is the name of the download link as from when i hover my pointer over download link.
End Sub

View 1 Replies View Related

Find Filename In Folder

Apr 10, 2007

I have created a separate SAVE button that when the user hits that button, it saves the file in a network drive using the current date as part of the save-file name. Ie: Sheet20070408.xls, Sheet20070409.xls, Sheet20070410.xls, and Sheet20070411.xls.

I am currently working out all the "idiot proof" safety features. My code looks something like this:

oldfilename = ActiveWorkbook.FullName
newfilename = "C:NetworkFolder" & format(date, "yyyymmdd") & ".xls"
ActiveWorkbook.SaveAs Filename:=newfilename
ActiveWorkbook.SaveAs Filename:=oldfilename

Why am I saving it twice? When the user clicks SAVE, I want to save over the copy of the current sheet they use, even if they save it on their desktop, and then save it to the network drive. This way, if they keep a second copy in an easy to find location, it will save the data to that sheet as well. Just in case they forget to save on the current sheet. I need to be sure each copy of the file has the most up-to-date information, as well as save a copy for retention.

My question is this: Can I search a folder for an existing file name? If the user goes into the network drive to open an old file for retention and they click SAVE, I don't want to accidentally overwrite a file in the retention folder.

View 4 Replies View Related

For All Workbooks In Folder - Copy Range To Different Workbook - Save To New Folder?

Apr 21, 2014

I have up to 50 workbooks in one folder with data in a specific range. I also have one workbook which includes additional data, including conditional formatting and dropdowns. I need to copy the desired range from the first workbook in the source folder to the second workbook, then save the latter to my destination folder, using the same name as the first. I need to repeat this process for all workbooks in the source folder.

View 2 Replies View Related

Save As File Name With A Cell Value As The Folder

Nov 26, 2007

i currently have a macro on my sheet which when the file opens will chaneg a cell value by +1 and save the new worksheet as that value.

What i would like is for the new worksheet to automatically save in a new folder relevant to another cell value. So i can save the sheets in job no order.

Can't seem to get it to work....

Here is a copy of my macro so far:

Sub SequentialNumber()
Const InitialValue = 1
Const increment = 1
Const prefix = ""
Const suffix = ""

Dim existSN As Boolean
Dim existMF As Boolean
Dim master As Boolean
Dim cdp As DocumentProperty
Dim SeqNumber As Long
Dim FSName As Variant

existSN = False
existMF = False
master = False.........

View 9 Replies View Related

Populate A Combo Box With The Filename From A Folder In VBA

Aug 17, 2009

I am trying to populate a combo box with the filename from a given folder, ideally without showing their .xls extension if possible.

View 12 Replies View Related

Get File From Cell Values And Save In Another Folder

Mar 2, 2007

I want to add the columns in the attached sheet...any 4,say A,C,D and F.....as follows,if the number in the cell is less than .8,I want use 1 in the sum,otherwise zero. I would like to do this in 1 column if possible. in the attached sheet,I have filled in manually the answer in column L....Thus row 1 contained no numbers less than .8 in the selected columns,where as row 8 had all four numbers less than .8.

View 6 Replies View Related

List Filename, Location & Attributes Of Files In Folder

May 21, 2008

Sorry that I'm very new in Excel VBA coder. And, for this topic, I don't even know how to start. I want to make a MS Excel database of a numerous files. This database must be consist of Filename, Location, and it's attribute (let's say updated date, size, hidden status)

View 2 Replies View Related

Excel 2010 :: Macro To Save Multiple Sheets To Multiple PDF With Cell Value As Filename

May 6, 2014

I would like a macro to be able to save 26 tabs within the one document to individual PDFs.Preferably I would like to be able to specify each time exactly which tabs get printed, because often I don't need to print all 26, just the first 10 or so.I would like each PDF to automatically be named with the value in cell E10 of each tab.E10 already has a formula to create its final value. It references cells from other tabs within the same document. Hopefully the fact that this cell has a formula in it won't affect my ability to use the resulting value as a 'save as' reference?I would like it if the PDFs save to the same location as the Excel sheet from which they're generated is located. The location of the excel sheet will change every three months, so I'd prefer not to specify a location with a specific filepath, as it will have changed by the time I run the macro again.

I am using Excel 2010.

View 5 Replies View Related

Image Folder - Save 500 Images In Another Folder?

Jul 18, 2014

I have a list of items in an excel sheet... 500 of them... and there are images for them in an other folder... The problem is those images are in 1000's and I only need those 500 images.. Images are saved as "SKU.jpg eg NS2354.jpg and we have an SKU column in excel as well .. SKU and their images have same name...

Is there any solution to pick up only those 500 images from those thousands of images?

Is it possible to save those 500 images in an other folder?

View 2 Replies View Related

Macro To Locate Folder In A Folder And Save

Apr 13, 2009

looking for some code to save to a destination

destination address is
C:Documents and SettingsstDesktopOJF

now the problem is OJF has folders named 1 to 500

so if cell d5 = 487 it will need to look in the above desination and then open the folder and save it there.

View 10 Replies View Related

Save The Filename

Sep 11, 2009

I have a problem with the following code

View 2 Replies View Related

Macro To Save Duplicate File And Create Folder Name Based On Cell Value

Nov 25, 2009

I currently use the following code to create a duplicate file based on two cells within a directory and folder i specify. These cells consist of the team and week commencing date (mondays date of week which is cell 'Main Menu'!K8)

View 7 Replies View Related

Excel 2003 :: Renaming All FileName In Folder Using Macro At Time With Different Names

Sep 23, 2010

Now iam Working in excel 2003, I got a Requirement that, After Downloading datas From SAP, It Directly Stored in Excel Sheet , Using tht Sheet1, I need to rename all the Filenames at a time, Is It possible, Any code is there to rename,

For Example,

From SAP to Excel Sheet Datas are Like this in Sheet1,

DmsNo Filename
50007685 SDFFG.jpg
50004678 HGJKID.jpg
50003421 VGFTHR.jpg

Then i have rename that filename, rename 'SDFFG.jpg' To '50007685.jpg', and it Should be directly rename to my Source File.

For Example:
Source File: C: estSDFFG.jpg

After renaming it Should be,

Source File: C: est50007685.jpg

any code is there to rename,

View 4 Replies View Related

Excel 2003 :: Browse For Text File When Folder Root Is Known But Filename Unknown

Apr 25, 2012

I have run into a problem in a project where I know what the folder root of the file I would like to import into excel is, but I do not know the file name.

I would like to open a dialogue open where I can select the file I wish to import from the known root supplied and retain the file name as a string.

All solution I have read assume the full file root is know or file name is known but root is unknown

I am working with Excel 2003.

View 2 Replies View Related

How To Link A Cell To Specific Image File To Other Folder

Jun 26, 2014

There is a problem in joining one cell to the other file

The below is screen shot when l click the on every cell the image must be open

How can do it?

Capture.PNG

View 1 Replies View Related

Save Workbook Using Variable For Save As And For A New Folder Name

Jul 31, 2009

I have figured out how to save the workbook using a variable to saveas but I would like to create a new folder to place the new workbook into. I have tried a few things a am not having any luck. I recorded a macro and the code it produced is as follows.

View 6 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved