[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference vaxuum::document_ft

Title:DOCUMENT T1.0
Notice:**New notesfile (DOCUMENT.NOTE) now available (see note 897)**
Moderator:CLOSET::ADLER
Created:Mon Feb 09 1987
Last Modified:Thu Oct 31 1991
Last Successful Update:Fri Jun 06 1997
Number of topics:897
Total number of notes:4397

95.0. "DCL Symbol interferes with /PRINT" by CSSE32::PITCHER (Steve Pitcher/CSSE-VMS/VAXclusters) Thu Mar 12 1987 09:27

    The DOCUMENT /PRINT fails for me, consistently.
    
    The problem is that I have a DCL symbol defined for PRINT, and it
    interferes with DOCUMENT's PRINT command.  Most DIGITAL products
    that issue DCL commands on behalf of the user first do something
    like:
    
    	$ PRINT := PRINT
    
    to insure that user defined symbols don't interfere.  I'd suggest
    doing this.
    
    Better still, I find it surprising that DOCUMENT is doing a DCL
    command.  Its generally more efficient (if not better for other
    reasons... Perhaps just my personal esthetics) to use the system
    service $SNDJBC.  Granted, if you want users to be able to give
    any PRINT command qualifier, this means lots of parsing for you.
    
    Same undoubtedly applies to the /BATCH.
    
    -	stp
T.RTitleUserPersonal
Name
DateLines
95.1How Do You Define Your Symbol?VAXUUM::ETZELMikeThu Mar 12 1987 10:1016
    Steve,
    
    You probably have a valid point for the product. For folks
    using bl07 though, why don't others have trouble using /PRINT= or /BATCH=
    when, for instance, many people use global symbols (process or
    system-wide) like:
    
    	PR*INT :== PRINT/NOTIFY 
    	SUM*BIT :== SUBMIT/NOPRINT/KEEP/NOTIFY?
    
    How do you assign your symbol name? Using a /QUE= qualifier? I use 
    a specific symbol name instead of the PRINT command for a specific 
    printer, such as:
    
    	LN03 :== PRINT/NOFEED/PASSALL/QUE=LN03_PRINT/NOTIFY
    
95.2LIB$DO_COMMAND()VAXUUM::DYERDays of Miracle and WonderThu Mar 12 1987 16:363
Redefining the PRINT symbol wouldn't work, because it's not being done in a
 subprocess.  DOCUMENT chains to the PRINT command.
  <_Jym_>
95.3workaround ?50372::CAAHANSHans Bachner, ADG MunichFri Mar 13 1987 06:5911
    What about the following workaround (for DOCUMENT, not for the user):
    
    CALL LIB$DO_COMMAND ('$ PRINT_COMMAND_WITH_FANCY_STUFF rest of your
    				command')
    
    PRINT_COMMAND_WITH_FANCY_STUFF is most unlikely to collide with
    any user defined DCL symbol; and as DCL parses only the first four
    characters not bothering about the rest you get back your original
    DCL PRINT command.  :-)
    
    Hans
95.4$SNDJBC ?SHIRE::ZGRAGGENSearching for infinity...Fri Mar 13 1987 09:374
    Why doesn't DOCUMENT use the $SNDJBC system service to queue print
    jobs?
    
    Peter
95.5{RE .3 & .4}VAXUUM::DYERDays of Miracle and WonderFri Mar 13 1987 13:4824
{RE .3} - A reasonable approach for the short term.  PRINT_DOC$, perhaps?

{RE .4} - Chaining to the PRINT and SUBMIT commands bought a lot.  It meant that
 all the features of your system's PRINT and SUBMIT commands are available even
  if they weren't available on the system DOCUMENT was developed on (we're still
   running VMS V4.2).  Our documentation simply says that the keywords are the
    same as the qualifiers to the PRINT and SUBMIT commands, which is preferable
     to having a list of printing/submitting keywords that aren't exactly like
      the ones available to PRINT and SUBMIT (which can be confusing).

It is possible to write code that figures out VMS version and only implements
 what's available on that version of VMS, using $SNDJBC, but I had something
  better in mind.

There are a lot of products with a PRINT feature, and they usually implement
 a subset of the PRINT qualifiers/keywords.  So here we have a lot of people
  reinventing the wheel:  parsing these keywords and calling $SNDJBC.  We seem
   to be screaming for an RTL-like interface to $SNDJBC, which parses the qual-
    ifiers/keywords that PRINT uses and calls $SNDJBC.

But there wasn't time to do that for field test, so instead of reinventing the
 wheel, I used SUBMIT.EXE's wheels.
  <_Jym_>
         
95.6Hows that go again?BUNSUP::LITTLETodd LittleTue Mar 17 1987 15:2415
re: .3

How is that supposed to solve the problem?  Many times I have seen symbols
defined as:

$ PRI*NT :== PRINT/NOTIFY/etc

Having DOCUMENT chain to $ PRINT_COMMAND_WITH_FANCY_STUFF is still going
to get that symbol.

Personally I love the ability to get qualifiers added to the print and
submit features by simply defining a symbol.  Until user settable command
defaults come into being, symbol definition is the easiest thing to do.

-tl
95.7it *does* work50372::CAAHANSHans Bachner, ADG MunichWed Mar 18 1987 05:1623
>    How is that supposed to solve the problem?  Many times I have seen symbols
> defined as:
>
> $ PRI*NT :== PRINT/NOTIFY/etc
>
> Having DOCUMENT chain to $ PRINT_COMMAND_WITH_FANCY_STUFF is still going
> to get that symbol.

    This is *not* true. Your symbol definition replaces any of the strings
    PRI, PRIN, and PRINT with PTINT/NOTIFY/etc but *nothing else* as
    a symbol definition $ PRI*NT* is not (yet ?) available. So any verb
    with at least one character following the string PRINT will not
    be recognized as a valid symbol, but will be passed to the CLI which
    is the guy that does the truncation, i.e. that looks at the first
    four characters only and forgets about the rest.
    
    Anyway, it's a good idea to document the verb used (e.g. the one
    suggested in .5) so it still is user-redefinable (maybe with some
    hints in the documentation to avoid conflicting qualifiers).
    
    Hans
    
       
95.8Next time I'll check!BUNSUP::LITTLETodd LittleFri Mar 20 1987 14:255
Oops, my error.  I stand corrected.  I forgot that DCL only uses the
asterisk as an indication of possible abbreviations.

-tl