I have been successfully using a macro that I learned here a few years ago but it stopped working. It doesn't show up in Macros anymore and I can't open the editor by using Alt+F11. When I try, it says out of memory.
Now, this is affecting every Excel workbook I am in--which do not have their own Macros. An error pops up in the other workbooks that says Can't find project or library (Visual Basic for Applications) after I hit okay, a dialog box called "References-VBA Project" pops up.
This is my macro: (to print a page # on each sheet)
[TABLE="width: 64"]
<tbody>[TR]
[TD="class: xl140, width: 64"]Sub PgNumbs()[/TD]
[/TR]
[TR]
[TD="class: xl140"] For i = 1 To 50[/TD]
[/TR]
[TR]
[TD="class: xl140"] With Sheets("WorkOrders")[/TD]
[/TR]
[TR]
[TD="class: xl140"] .PageSetup.RightHeader = "Page " & i[/TD]
[/TR]
[TR]
[TD="class: xl140"] .PageSetup.FitToPagesWide = 1[/TD]
[/TR]
[TR]
[TD="class: xl140"] .PageSetup.FitToPagesTall = 1[/TD]
[/TR]
[TR]
[TD="class: xl140"] .PrintOut Copies:=1[/TD]
[/TR]
[TR]
[TD="class: xl140"] End With[/TD]
[/TR]
[TR]
[TD="class: xl140"] Next[/TD]
[/TR]
[TR]
[TD="class: xl141"] end sub[/TD]
[/TR]
</tbody>[/TABLE]
Anyone have any ideas to help? I am not a proficient Macro user but was so happy to learn from everyone here and help out with a weekly chore by way of a macro. Thanks !
Now, this is affecting every Excel workbook I am in--which do not have their own Macros. An error pops up in the other workbooks that says Can't find project or library (Visual Basic for Applications) after I hit okay, a dialog box called "References-VBA Project" pops up.
This is my macro: (to print a page # on each sheet)
[TABLE="width: 64"]
<tbody>[TR]
[TD="class: xl140, width: 64"]Sub PgNumbs()[/TD]
[/TR]
[TR]
[TD="class: xl140"] For i = 1 To 50[/TD]
[/TR]
[TR]
[TD="class: xl140"] With Sheets("WorkOrders")[/TD]
[/TR]
[TR]
[TD="class: xl140"] .PageSetup.RightHeader = "Page " & i[/TD]
[/TR]
[TR]
[TD="class: xl140"] .PageSetup.FitToPagesWide = 1[/TD]
[/TR]
[TR]
[TD="class: xl140"] .PageSetup.FitToPagesTall = 1[/TD]
[/TR]
[TR]
[TD="class: xl140"] .PrintOut Copies:=1[/TD]
[/TR]
[TR]
[TD="class: xl140"] End With[/TD]
[/TR]
[TR]
[TD="class: xl140"] Next[/TD]
[/TR]
[TR]
[TD="class: xl141"] end sub[/TD]
[/TR]
</tbody>[/TABLE]
Anyone have any ideas to help? I am not a proficient Macro user but was so happy to learn from everyone here and help out with a weekly chore by way of a macro. Thanks !