Regards,
Tom Ogilvy
Kerry B. Mackey wrote in message <3737A49A...@pickapart.com>...
I have been able to download the MS Tech Support Application Note
12/96-WE1277 entitled "Visual Basic for Applications Equivalents for Lotus
1-2-3 Macro Commands". This is a great source of information but I am having
a problem with the automation of a print macro developed in Lotus 1-2-3
v5.0. Here is the Lotus print macro (highlighted areas = Lotus range names):
ZSTART (Main Macro)
{Choose-Item ZALL;ZFLAG;"Highlight desired selection:...";"Main Print
Menu"}
{IF @cell("type";ZFLAG)="b"}{quit}
{IF ZFLAG=0}{Branch ZALLPR}
{IF ZFLAG=1}{Branch ZHIST}
{IF ZFLAG=2}{Branch ZSTATS}
{IF ZFLAG=3}{Branch ZASSUMP}
{IF ZFLAG=4}{Branch ZCIP}
{IF ZFLAG=5}{Branch ZPROJ}
{IF ZFLAG=6}{Branch ZBRK}
{IF ZFLAG=7}{Branch ZMISC}
ZALL (Main Print Menu)
0 PRINT ALL SELECTIONS
1 HISTORICAL
2 STATISTICS
3 ASSUMPTIONS
4 CAPITAL IMPROVEMENTS
5 PROJECTIONS
6 MONTHLY ANALYSIS
7 MISCELLANEOUS
ZFLAG 1 (Selection = HISTORICAL)
ZHIST (Historical Info Print Menu)
{WINDOWSOFF}
{CHOOSE-MANY ZA,ZFLAG,"Enter selection(s):...","Historical Print Menu"}
{IF ZFLAG=0}{BRANCH ZSTART}
{IF ZAF1=1}{ZA1}
{IF ZAF2=1}{ZA2}
{IF ZAF3=1}{ZA3}
{IF ZAF4=1}{ZA4}
{IF ZAF5=1}{ZA5}
{WINDOWSON}
1 ZHIST (Historical Info Print Menu)
ZA (lists the following menu choices)
A - Print All Selections
B - Print Sales Information
C - Print Cost of Sales Information
D - Print Admin and Misc Inc/Exp
E - Print Inventory Reconciliation
ZAF2 (Print Sales Information Option) = 1
ZA2 (Print Sales Information Option)
{INDICATE "Printing Sales Information"}
{SET "PRINT-HEADER-LEFT-TEXT";""}
{SET "PRINT-HEADER-CENTER-TEXT";""}
{SET "PRINT-HEADER-RIGHT-TEXT";""}
{SET "PRINT-FOOTER-LEFT-TEXT";"@ +"}
{SET "PRINT-FOOTER-CENTER-TEXT";""}
{SET "PRINT-FOOTER-RIGHT-TEXT";"^"}
{SET "PRINT-SIZE";"FIT-ALL"}
{SET "PRINT-ORIENTATION";"PORTRAIT"}
{SET "PRINT-MARGIN-TOP";"0.5in"}
{SET "PRINT-MARGIN-BOTTOM";"0.5in"}
{SET "PRINT-MARGIN-RIGHT";"0.5in"}
{SET "PRINT-MARGIN-LEFT";"0.5in"}
{SET "PRINT-CENTERED";"HORIZONTAL"}
{SET "PRINT-WORKSHEET-FRAME";"OFF"}
{SET "PRINT-GRID-LINES";"OFF"}
{SET "PRINT-DRAWN-OBJECTS";"OFF"}
{SET "PRINT-TITLES-CLEAR";"COLUMNS"}
{SET "PRINT-TITLES-ROW-RANGE";"HISTHDR"}
{SET "PRINT-RANGE";HISTSLS}
{PRINT ;1;9999;1;1}
{SET "PRINT-TITLES-CLEAR";"COLUMNS"}
{SET "PRINT-TITLES-CLEAR";"ROWS"}
{INDICATE}
This print menu has many different selections to choose from - the tech
support application note says to use "userforms" for the {Choose-Item},
{Choose-Many} Lotus macro command language. Well, this is great, but how do
you develop and utilize (automate/activate) the userforms in a print macro
using visual basic in Excel '97? I have tried to establish the userform, but
cannot figure out how to activate the macro commands from the userform. How
does the macro call the userform? Do you record the macro commands and
somehow link/reference the userform to call several different print options?
What if you wanted to have the ability to select more than one print option
from the userform? Is this the right direction to be taking for macro
automation? HELP...
I am also looiking for help with the {IF
@cell("type";ZFLAG)="b"}{quit}listed above as well.
Any help would be greatly appreciated. Thank you.
Regards,
Kerry Mackey
Thank you for any assistance that you may provide.
Regards,
Kerry Mackey