![]() |
|
![]() |
|
Thread Tools | Search this Thread | Display Modes |
#1
|
|||
|
|||
![]()
Because I change the name of the Workbook each time I use it I can’t use: Application.Run "'G BAKER ESTIMATING FORM.xls'!SAVEDATA2"
ActiveWindow.SmallScroll Down:=12 Application.Run "' G BAKER ESTIMATING FORM.xls'!savedata" Range("L8").Select Sub SAVEDATA2() ' ' SAVEDATA2 Macro ' Macro recorded 03/24/2010 by Gary W. Baker ' Keyboard Shortcut: Ctrl+s ' Dim row, rwindex As Integer row = 0 rwindex = 5 Range("U14:BO14").Select Selection.Copy Sheets("DATA").Select Range("C1").Select Do ActiveCell.Offset(1, 0).Activate Loop Until ActiveCell.Value = "" Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _ False, Transpose:=False Sheets("To CUSTOMER").Select Application.CutCopyMode = False Range("l8").Select End Sub Sub savedata() ' ' save Macro ' Macro recorded 3/08/2010 by Gary Baker ' ' Keyboard Shortcut: Ctrl+s ' Dim row, rwindex As Integer row = 0 rwindex = 5 Range("U14:BO14").Select Selection.Copy Workbooks.Open Filename:=" W:\Other\ESTIMATE REPORTS\ESTIMATE DATA.xls" Sheets("DATA").Select Range("C1").Select Do ActiveCell.Offset(1, 0).Activate Loop Until ActiveCell.Value = "" Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _ False, Transpose:=False Range("A1").Select ActiveWorkbook.Close Application.CutCopyMode = False Range("l8").Select End Sub |
#2
|
||||
|
||||
![]()
You can simply copy the SAVEDATA2 sub to the other Excel document. Then you would be able to call it from savedata or just copy the code and past it to the end of savedata. That would work also.
-Shelby |
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Combine Textrows... | WernerHo | Macros/Add-ons | 6 | 15-12-2009 11:44 |
Adding a button to toolbars to run a VBA macro | Alex | FAQ | 4 | 10-05-2007 09:07 |
Cancelling a macro when hitting the "Cancel" button | annedeblois | CorelDRAW/Corel DESIGNER VBA | 1 | 23-03-2006 17:05 |
Corel 9 VBA Weld and Combine | korner | CorelDRAW/Corel DESIGNER VBA | 2 | 07-10-2004 11:48 |
ESC button..... ESC!!! | dungbtl | General | 0 | 28-08-2004 16:39 |