AnsweredAssumed Answered

vrf Custom Menus (was Version 7 - System menu with printerchoi

Question asked by warren.pickles on Apr 6, 2004
"Custom menus are useful for putting commonly used functions on a menu for
easy access. "

That should read "commonly used code" not "commonly used functions".

Custom menus can't be used to put userfunctions into the workspace, only
userobjects, or code samples.  When you select a custom menu item you get a
clone of the code in Main in a specific VEE file, but not its userfunctions.
So if you use that menu item multiple times, you get clones of the same code
doing the same thing.  That's the situation where you should be using a
userfunction.  Custom menus are a very handy thing, but they encourage bad
programming practice in that respect.

What I plan to do is put the code from each file referenced in the VEE 7
custom menus into a user function in a dedicated global library which will
be imported by all my VEE programs.  Then change the menu files so that they
contain only a call to the appropriate function.

(The files containing the code called up by the system menu are all under
the Lib directory in the VEE installation directory).


-----Original Message-----
From: MEANEY,TIM (A-USA,ex1) []
Sent: 05 April 2004 16:53
Subject: [vrf] RE: AW: RE: Version 7 - System menu with printerchoice ?

Hi Detlef,
>Cant you provide an item there to switch to different printers? To solve an
>old problem also from all the others who want to print once on a  standard
>printer and also to a .pdf file or a different printer, maybe one landscape
>and one portrait ? Within one VEE Session .
The system menu has an object titled "What is this menu". This object is a
notepad with info about the new system menu and how to customize it. I have
cut and pasted a portion of this section below.
Customize this menu
All the operations on the System menu are created using the custom menu
functionality in VEE.  Custom menus are useful for putting commonly used
functions on a menu for easy access.  You can see how it is done if you edit
the file named System.mnu  in the VEE installation directory.  To edit the
file, use any ASCII text editor such as Notepad or Wordpad.  There are more
details on creating a custom menu in the file named <VEE install dir>  lib
customMenu.mnu file.
>The example below provided by Tim is not 100%
>running so far....
I have tried your attached vee program on my system, substituting the names
of three printer I have installed. Two are pdf printers and one is a
networked printer. The program seems to reliably switch default printers for
me and then prints without error. What problems are you experiencing?
-----Original Message-----
From: Baranski, Detlef []
Sent: Monday, April 05, 2004 11:01 AM
To: PDL-LISTS,VRF (A-Lists,unix1)
Subject: [vrf] AW: RE: Version 7 - System menu with printerchoice ?
Hi Scott and the vrf,
thanks for your hints - until now i did not see the system menu
Cant you provide an item there to switch to different printers? To solve an
old problem also from all the others who want to print once on a  standard
printer and also to a .pdf file or a different printer, maybe one landscape
and one portrait ? Within one VEE Session .
Is it possible to do so ? The example below provided by Tim is not 100%
running so far....
One other observation:
If i install the Eval - Pro7 Version to harddisk D:, and i have a runtime
and Development Version 6.01 and 6.2 Version installed before,
the .vee programs are still opening Version 6.01...which seems to be good
for downcompatibility Its not a bug now ...
-----Ursprngliche Nachricht-----
Von: BAYES,SCOTT (A-Loveland,ex1) []
Gesendet: Samstag, 3. April 2004 01:10
Cc: Barrie Walden
Betreff: [vrf] RE: Version 7
Hi Barrie and the vrf,
> I see a lot of energy going into "Vee's place in the world"
> discussions
> and, curiously, almost nothing about the Ver 7.0 release.  Does this
> mean few have tried it or nobody wants to talk about it?
Very good point, Barrie, though here in Agilent we're still finding lots of
interest in the topics Jeff started about VEE's place in the world, and are
learning a lot from them.
Anyway, to get going with .NET I found the best way is not to pick up a
heavy book, but to start with 2 goodies that we included in 7.0:
- the System menu, between the existing Device and IO menus. Lots (100 or
so) of small but useful snippets there, instant gratification from mostly
one-liners. Finding your IP address is dead easy with this (Environment
- the Help menu, select the Open example... item, go to DotNET directory. 29
fairly useful and instructive examples there, if I counted correctly. More
instant gratification and mostly simple enough to understand with little
.NET background, especially if you've already done battle with ActiveX.
The DrawOnBitMap example is kind of neat, you can do all kinds of drawing,
then display it on a VEE Picture object, integrate to a Panel if you like.
Pretty easy to see how it's done from this example.
Once you've seen (some of) what .NET is good for and played with it a bit,
you probably want to go and read Chapter 7 of the 7.0 User's Guide for
gritty details.
If you got a 7.0 upgrade, this new version of the manual will be in the box.
If you're using the eval download, don't throw the unzip-ped files away
until you grab the User's Guide from the Books directory. If you've already
deleted this stuff, go to < >, get logged in, and
choose the Drivers/Downloads link on the right of the page. Select Software:
VEE Pro > VEE Pro. The 7.0 User's Guide is a 7 MB download on that page.
This is also a good place to get a copy of 7.0 to try out if you haven't
already done so.
Advanced Techniques and the Tutorials didn't change for 7.0, so you've
really only got one chapter to read, chapter 7. Other 7.0 changes are
scattered through the manuals, and you probably will figure them with little
trouble, even without reading about them.
Once you've read the hardcopy or pdf, you may want to know where you can get
a refresher course on .NET or all of VEE.
The Help menu, Contents and Index gets you to the new Online Help system.
There's a cool little browser tool there, beside the long yellow box with
the icons in it near the top. It will open up on the .NET Framework topic
when you first start up Help. It takes you on a guided path through .NET
usage. But it also covers a bunch of other VEE topic areas. This thing might
also be pretty good for colleagues who are new to VEE altogether.
After you've played with these features would be a good time to decide
whether you want to get a book on .NET.
Re the Properties Window: I think I'll get to like it more as I use it more.
Right now I keep right-clicking on objects before I think of going to the
new window. Muscle memory.
I guess one of the main things I notice is that it's more standard than the
previous right-click dialogs, so there's a bit less of a mental gear change
required when I start to use VEE after using something else. Same with Undo
using CTL-Z, pretty standard. "Standard is better than better"
Best Regards,
Scott Bayes
Software Technical Support
Agilent Technologies, Inc.
815 14th Street S.W.
Loveland, CO, U.S.A. 80537
970 679 3799 Tel
970 635 6867 Fax
This message and any attachments are confidential, for the exclusive use of
the addressee and may be legally privileged. Any other distribution, use or
reproduction is unauthorised and prohibited. If you have received this
message in error, please notify the sender immediately and delete the
message from your system.
Visit our internet site at

You are currently subscribed to vrf as:
To subscribe send a blank email to "".
To unsubscribe send a blank email to "".
To send messages to this mailing list,  email "". 
If you need help with the mailing list send a message to "".