ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   File saved as cell entry macro (https://www.excelbanter.com/excel-programming/338971-file-saved-cell-entry-macro.html)

xyzer

File saved as cell entry macro
 

I am looking for a macro that when activated by a button will rename the
file to a cell entry (part number) and save the renamed file to a set
directory. Is this possible?
Thanks in advance!


--
xyzer
------------------------------------------------------------------------
xyzer's Profile: http://www.excelforum.com/member.php...o&userid=26899
View this thread: http://www.excelforum.com/showthread...hreadid=401235


Dave Peterson

File saved as cell entry macro
 
I would think it would contain something like:


with activeworkbook
.SaveAs Filename:="c:\yourpath\" _
& .worksheets("sheet1").range("a1").value
end with

But remember that there are characters that are not allowed in a filename
(slashes come to mind).


xyzer wrote:

I am looking for a macro that when activated by a button will rename the
file to a cell entry (part number) and save the renamed file to a set
directory. Is this possible?
Thanks in advance!

--
xyzer
------------------------------------------------------------------------
xyzer's Profile: http://www.excelforum.com/member.php...o&userid=26899
View this thread: http://www.excelforum.com/showthread...hreadid=401235


--

Dave Peterson


All times are GMT +1. The time now is 01:28 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com