ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   HELP! saving as xls in current folder (https://www.excelbanter.com/excel-programming/350758-help-saving-xls-current-folder.html)

drumerboy[_7_]

HELP! saving as xls in current folder
 

This code saves xls sheets as a csv files. BUT I do not know:
1. how to save them as xls.
2. how to save in the parent current folder

For i = 1 To nr
Nume = Cells(i + 2, 1)
Worksheets(Nume).Activate
Fisier = "C:\Back-up\Developers\Mario\" & Nume & ".csv"
ActiveSheet.SaveAs Fisier, xlCSVWindows
Worksheets("SA 200").Activate
Next i
End Sub

Please help me


--
drumerboy
------------------------------------------------------------------------
drumerboy's Profile: http://www.excelforum.com/member.php...o&userid=30468
View this thread: http://www.excelforum.com/showthread...hreadid=502431


DaveO

HELP! saving as xls in current folder
 
Quickest way to find this type of info out is to record a macro that saves
the sheet where you want it saved. Then edit the macro and copy it and paste
it into the code you have below.

HTH

"drumerboy" wrote:


This code saves xls sheets as a csv files. BUT I do not know:
1. how to save them as xls.
2. how to save in the parent current folder

For i = 1 To nr
Nume = Cells(i + 2, 1)
Worksheets(Nume).Activate
Fisier = "C:\Back-up\Developers\Mario\" & Nume & ".csv"
ActiveSheet.SaveAs Fisier, xlCSVWindows
Worksheets("SA 200").Activate
Next i
End Sub

Please help me


--
drumerboy
------------------------------------------------------------------------
drumerboy's Profile: http://www.excelforum.com/member.php...o&userid=30468
View this thread: http://www.excelforum.com/showthread...hreadid=502431




All times are GMT +1. The time now is 08:06 AM.

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