Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi,
Is there any way, using Excel VBA code, we can move a worksheet from one folder on the system to another. Can someone give me an example code. Thanks in advance Prasad Vanka |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Sub move()
Dim path As String Dim fil_nam As String path = "D:/" ' Specify Path you want to move to, you can also do this by 'passing a vairable fil_nam = ActiveWorkbook.Name del_file = ActiveWorkbook.FullName ActiveWorkbook.SaveAs (path & fil_nam) Kill ActiveWorkbook.Name End Sub Prasad Vanka wrote: Hi, Is there any way, using Excel VBA code, we can move a worksheet from one folder on the system to another. Can someone give me an example code. Thanks in advance Prasad Vanka |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
More simply
name "C:\myTest\Volker1.xls" as "C:\NewDir\Volker99.xls" note that NewDir must exist already. -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "yogendra joshi" wrote in message ... Sub move() Dim path As String Dim fil_nam As String path = "D:/" ' Specify Path you want to move to, you can also do this by 'passing a vairable fil_nam = ActiveWorkbook.Name del_file = ActiveWorkbook.FullName ActiveWorkbook.SaveAs (path & fil_nam) Kill ActiveWorkbook.Name End Sub Prasad Vanka wrote: Hi, Is there any way, using Excel VBA code, we can move a worksheet from one folder on the system to another. Can someone give me an example code. Thanks in advance Prasad Vanka |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
VBA to move an excel file to another folder | Excel Discussion (Misc queries) | |||
Move Active Workbook to another Folder | Excel Discussion (Misc queries) | |||
move a sheet out of my workbook and place in another folder? | Excel Discussion (Misc queries) | |||
Move Folder Contents | Excel Programming | |||
Move file to different folder | Excel Programming |