Hi Michael,
I have done something like this before using STR-MGR.COM and STE-BASE.STR
where I grafted a menu on to a different menu.
If you are not familiar with STR-MGR and the STE-BASE.STR it at first can
seem a little daunting... Firstly STE-MGR.COM reads an existing .STR file,
and creates an file in the form of a Synthetic Transaction Log. This file
include the definition of panels, fields, indexs etc and Menu text and
options.
You can make CAREFUL changes to part of the database, but not for the feint
hearted. You require an understanding of the impact that changes might have
so for example if you changed a panels specification that affects indexes,
or its data file then you can cause all sort of headaches... On the reports
Menu there is a standard "Produce .STE file", which you can then use with an
.STE file which using DPIMP you can concert back to a .STR file... On the
other hand if you do not get too wild you can change Menu's without too much
problem.
I use it all the time, but for documenting databases, and sadly when needed
converting them to Access, or SQL server. I occasionally have changed
formulas, which I could have just as easily done with a text editor on an
STE file... The menu grafting was one of the biggest but possibly easiest
things I have used it for.
I usually just copy the original .STR file into an empty folder together
with DP.EXE, DP.SYS, DPIMP.EXE, STE-MGR.COM and the STE-BASE.STR. You do not
need the original data files, .IND or .TXX etc...
The Way I would approach your problem, is that I would create a new Menu
option on your existing Main Menu. (This eventually will be come the new
(2nd level) Main Menu and copy and paste the Menu Text from your existing
main menu... You can use any menu number for this, just remember that you
will need to start the application with /z=n where n is whatever menu number
you have chosen... Mind you you can change this later with STE-BASE.STR. Do
not both about creating any of the menu options for this, these can be
easily repointed later.
This should give you an STR with just one empty menu, containg just the Text
for what will become your new main menu. Use STR-MGR.COM to export a TLog
file .{L} and then Run DP.EXE using the STR-BASE.STR... Allow it to
re-create its .TXX and Index files, and you will get a list of panels. Open
any panel and Import the TLOG created by STR-MGR (Shift-F9 - 8 (Import
Transaction Log). This will populate all the various panels with your
database information.
The Two panels of interest to you will be the STE-BASE.MEN abd STR-BASE.OPT
panels. Start with the STR-BASE.MEN panel.. You should find that you
original Main Menu has MenuID of <Blank> whereas all the submenu's have
numbers. Go to the last Menu which should be your new Main Menu (text only)
and note its Menu ID. Exit the .MEN panel.
Open the STE-BASE.OPT panel and locate all the menu items for the Menu with
ID <blank> ie these are the Main Menu items, and for menu items except the
one that you created ealier to point to your new submenu (ie your new Main
Menu at the 2nd level), and change their MenuID to that of the MenuID you
noted in the previous panel.
Once you do this, you should have moved all the Menu Items over to your new
Main Menu, and if you wish to can change the Menu option for selecting your
submenu, and changes it option number to say 1.
If you wanted to preserve the original panel, you copy the Options record
and change it rather than the original...
Once you run the report to create the .STE file... and then use DPIMP to
create the .STR file. I generally copy back the new .STR file and delete
the .TXX and .IND and then when starting the application let DP recreate
them.
To change a menu with about 20 items, take about 10 minutes, and is a lot
easier than rebuilding from scratch. I should have to mention this, but
make sure all your original stuff is backed up, and that you test it all
before deployment.
Normally if you create a sub-menu from a menu, you get an empty menu with a
new id... I have often wondered if instead of this, if you could change the
SubMenu id in the Options menu, to point to an existing menu. I have often
frequently need structures where I find I am creating menu identical to
another menus especially when I have different roles needing to access
certain part of the application, but then need a common set of menu items
somewhere else. The STE-BASE certainly doesn't stop you from doing it, but
it has always made me nervous... It would be interesting if someone more
knowledgeable could tell me if omeone did that, would it be like "crossing
the streams" and then having "all life as you know stopping instantly and
every molecule in yor body exploding at the speed of light", which obviously
would not be a good thing, or is having two submenu option pointing to the
same submenu an ok thing to do.
Bye
Brian
----- Original Message -----
From: "Michael Iannantuoni" <[EMAIL PROTECTED]>
To: "Dataperfect Users Discussion Group" <[email protected]>
Sent: Tuesday, March 13, 2007 9:13 AM
Subject: Re: [Dataperf] Exiting from menu
Hi Brian,
Is there an easy way to do this or will I have to redefine my menu (now
sub menu) settings & reports?
Regards,
Michael
Brian Hancock wrote:
Hi Michael,
Exactly... The first one just controls the access, the submenu is the
first (and last) menu the user sees...
Regards
Brian
----- Original Message ----- From: "Michael Iannantuoni"
<[EMAIL PROTECTED]>
To: "Dataperfect Users Discussion Group" <[email protected]>
Sent: Monday, March 12, 2007 8:53 PM
Subject: Re: [Dataperf] Exiting from menu
Hi Brian,
Thanks for the suggestion - I tried /z=1 which bypasses my menu and
takes me to panel 1 but exiting exits completely without going to the
menu.
Were you suggesting moving my menu to a sub-menu and having an
effectively dummy main menu?
Regards,
Michael
Brian Hancock wrote:
I think there is...
The /z=n where n is a menu item on the first menu take the user to that
menu item which of course can be a submenu, or directly to a panel etc.
and when the user exits that menu item exits out without going through
the Create New Database etc screen... Its a way of hiding everything
but the menu options you choose from the user...
Regards
Brian
----- Original Message ----- From: "Michael Iannantuoni"
<[EMAIL PROTECTED]>
To: "DataPerfect Users Discussion Group" <[email protected]>
Sent: Monday, March 12, 2007 12:10 AM
Subject: [Dataperf] Exiting from menu
Is there a way of directly exiting from a menu without going through
the "Create New database/Change Directory" screen when a DataPerfect
database is not running under Shell and therefore unable to use
macros?
Thanks,
Michael
_______________________________________________
Dataperf mailing list
[email protected]
http://lists.dataperfect.nl/mailman/listinfo/dataperf
_______________________________________________
Dataperf mailing list
[email protected]
http://lists.dataperfect.nl/mailman/listinfo/dataperf
_______________________________________________
Dataperf mailing list
[email protected]
http://lists.dataperfect.nl/mailman/listinfo/dataperf
_______________________________________________
Dataperf mailing list
[email protected]
http://lists.dataperfect.nl/mailman/listinfo/dataperf
_______________________________________________
Dataperf mailing list
[email protected]
http://lists.dataperfect.nl/mailman/listinfo/dataperf
_______________________________________________
Dataperf mailing list
[email protected]
http://lists.dataperfect.nl/mailman/listinfo/dataperf