Displaying a standalone UIM panel?

5,520 pts.
Tags:
DDS
DDS Source
UIM QPNLSRC
V5R4
Suppose you wanted to provide users with the contents of a few pages of text coded as UIM panels.

There used to be a DSPHLPDOC which would show a resolved document from a folder. No Officevision (aka Displaywrite) now though.

Any ideas ??

- trying to avoid using a DDS screen of literals or coding 'something new' when the help text is already there... Thanks all



Software/Hardware used:
V5r4
ASKED: June 23, 2011  2:23 PM
UPDATED: June 30, 2011  1:00 PM

Answer Wiki

Thanks. We'll let you know when a new response is added.

of course it always seems that the list of “make it pretty” just keeps getting longer, because there are always more things to “make it work” than time

Discuss This Question: 6  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • TomLiotta
    If these are normal "help" panels, the Display Help (QUHDSPH) API can be used. I have a DSPHLPPNL command definition that uses the API as its CPP. It's not a pretty command, since I only use it for quick testing -- but it might be helpful. The API documentation itself is effectively the documentation you'd use for the command:
     DSPHLPPNL:  CMD        PROMPT('Display a help panel') /* QUHDSPH */
    
    /*  HLPIDARY: Help ID Array...                                      */
    
                 PARM       KWD(HLPIDARY) TYPE(QHLPIDARY) MIN(1) +
                              PROMPT('Qualified help panel name' 1)
     QHLPIDARY:  QUAL       TYPE(*NAME) LEN(10) MIN(1)
                 QUAL       TYPE(*NAME) LEN(10) DFT(*LIBL) +
                              SPCVAL((*CURLIB) (*LIBL)) PROMPT('Help ID +
                              panel library')
                 QUAL       TYPE(*CHAR) LEN(32) DFT(NONE) PROMPT('Help +
                              ID module name')
    
                 PARM       KWD(NBRHLPIDS) TYPE(*INT4) CONSTANT(1)
                 PARM       KWD(HLPTYP) TYPE(*CHAR) LEN(8) +
                              CONSTANT(X'0000000100000001')
                 PARM       KWD(HLPTTL) TYPE(*CHAR) LEN(55) +
                              CONSTANT('Help panel display')
                 PARM       KWD(HLPIDXSCH) TYPE(*CHAR) LEN(20) +
                              CONSTANT(*NONE)
    
                 PARM       KWD(HLPDSPTYP) TYPE(*CHAR) LEN(1) RSTD(*YES) +
                              DFT(*WINDOW) SPCVAL((*WINDOW N) (*FULL +
                              Y)) PROMPT('Window or full-screen?')
    
                 PARM       KWD(HLPUPRLFT) TYPE(*CHAR) LEN(8) DFT(*DFT) +
                              SPCVAL((*DFT X'0000001400000007')) +
                              PMTCTL(*PMTRQS) PROMPT('Help area - upper +
                              left')
                 PARM       KWD(HLPLWRRGT) TYPE(*CHAR) LEN(8) DFT(*DFT) +
                              SPCVAL((*DFT X'000000150000004F')) +
                              PMTCTL(*PMTRQS) PROMPT('Help area - lower +
                              right')
                 PARM       KWD(HLPCSRLOC) TYPE(*CHAR) LEN(8) DFT(*DFT) +
                              SPCVAL((*DFT X'000000140000001D')) +
                              PMTCTL(*PMTRQS) PROMPT('Cursor location')
    
    
    /*  ERRCOD: Required ERRCODE definition minimum...                  */
    
                 PARM       KWD(ERRCOD) TYPE(*INT4) CONSTANT(0)
    An example usage:
    DSPHLPPNL HLPIDARY('PDM/MBRL/OPTL1'/QPDA/QHUONLN)
    That should display the basic PDM help panel (QPDA/QHUONLN) showing the help for the 'Opt' column from the Work with Members Using PDM panel. You might run this:
    DMPOBJ OBJ(QPDA/QHUONLN) OBJTYPE(*PNLGRP)
    ...to see how that help panel looks as a compiled object. The spooled file might give you a sense of what happens. From there, you might be able to adapt to your own panel, perhaps by calling the API directly. Tom
    125,585 pointsBadges:
    report
  • Yorkshireman
    What a treat on a sunny Monday to roll in and discover such complete and succinct answers. Many thanks Tom, it took me mall of 8 minutes to copy and paste the code, fix the character conversion errors that prevented the file being displayed (ggod old seu!) and have a working command. Excellent! It took another 20 before I read the manual ! and found the panel name is case insentivive and insists on Upper case. so this now works a treat. WDSPUIM HLPIDARY(INTRO/TST22538/DPOWDFRH) HLPDSPTYP(*FULL) Back to being the iSeries evangelist! Many thanks Tom.
    5,520 pointsBadges:
    report
  • TomLiotta
    ...fix the character conversion errors that prevented the file being displayed... Conversion of pasted code or of characters in the UIM panel? I haven't seen any way to keep quotes/apostrophes from becoming right-quote/left-quote characters in this editor. It's kind of irritating. It's just something to adjust after copying. Characters in UIM panels, though, might have solutions. If it's all working now, it might not make any difference. The command allows quick prototyping with a way to see how the API handles some of the parms. It's probably better to call the API directly than use the command. A wrapper CL or HLL would format parameters similar to what the command does. Or the command can be used indefinitely. I tend slowly to replace this type of command (direct API wrappers) with CALLs. Once the first CALL works, it becomes a template for all others for the same API. The command is mostly a teaching (learning) tool to examine behavior of the API. Tom
    125,585 pointsBadges:
    report
  • Yorkshireman
    Good Morning Tom >>Conversion of pasted code or of characters in the UIM panel? Yes indeed. probably so called 'smart quote' character. I didn't take any time to investigate, on such a short section of code I just fixed it. . After realising the case issue with the API I mentally did a run-down of the time to convert to a CLLE call, and add some validation for the object existence, add 'standard' error checking/ messaging./ logging and the rest. And then moved on to more pressing matters. I'll probably return to it when the immediate stuff is out of the way - be happy to post my attempts at code. Richard
    5,520 pointsBadges:
    report
  • TomLiotta
    probably so called ’smart quote’ character. Yep. I try to paste first into Notepad and do a replace-all for all left- and right-quotes to get them both to be the plain ASCII apostrophe. Then I can drop it into a shared drive so CPYFRMSTMF puts it into a source member. Nearly all problems are gone at that point. ...when the immediate stuff is out of the way... Yep, again. Make it work first. Then make it pretty. That's what I always say sometimes. Tom
    125,585 pointsBadges:
    report
  • BigKat
    of course it always seems that the list of "make it pretty" just keeps getting longer, because there are always more things to "make it work" than time
    7,585 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following