Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Private subs
I have created the following private sub in my worksheet:
Private Sub CommandButton1_Click() ' Define a área de impressão ActiveSheet.PivotTables("Pivot Table Show Price").PivotSelect _ "Produto[All]", xlLabelOnly, True ActiveSheet.PageSetup.PrintArea = _ ActiveCell.CurrentRegion.Address Range("A1").Select End Sub So, now I want to create a macro to do perform some actions (see below) and to run this private sub as the last action of the macro below...how can I do this? Sub Copy_Log() Application.Goto Reference:="Log" Selection.Copy Workbooks.Open Filename:="S:\Finance\Pricing\General\TimeTable1.x ls" Sheets("DB").Select Application.Goto Reference:="Index1" Selection.End(xlDown).Select ActiveCell.Offset(1, 0).Range("A1").Select Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _ :=False, Transpose:=True Range("A1").Select Application.CutCopyMode = False ActiveWorkbook.Save ActiveWindow.Close End Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Combining two Subs | Excel Discussion (Misc queries) | |||
Stringing Subs | Excel Programming | |||
calling subs | Excel Programming | |||
Recursive Subs? | Excel Programming | |||
calling private subs | Excel Programming |