Good News Everybody!
The new search engine is LIVE!
Please report any problems to david (at) midrange.com.
|
Should not be anything special, do you have the library in your lib list
where you created the source physical file?
Here is also a copy of my subprocedures; tweaked from what Brad shows
in his book to make my specific life easier with regards to how I
store the "static" html code;
I know there are some "cooler" ways to do this, but I was in a
hurry, and fell into familiar habits, and just have not had the
time since V5R1 upgrade, let alone after I really understood
what I was doing to go back and "fix" the code - oh well this
gives you the general idea.
I "retrieve" both these source members via a /copy.
I also tend to just put them all in my cgi programs if I use them
or not, just more of a "standard" in case for some reason I decide
to use a function later on, and don't have to go through the
embarrassment of the compile bombing because I forgot to copy in
the subprocedure(s).
*//////////////////////////////////////////////////////////////*
* (#WrtSrcMbr) Write data file member to HTML form *
* *
* Use: #WrtSrcMbr(Library : File : Member) *
* *
*//////////////////////////////////////////////////////////////*
#WrtSrcMbr B EXPORT
*--------------------------------------------------------------*
#WrtSrcMbr PI
Lib 10 VALUE
File 10 VALUE
SrcMbr 10 VALUE
NewLine C CONST(X'15')
pos S 5U 0
pos2 S 5U 0
D WrtDta S 20480
D QCmdCmd S 512 INZ
D QCmdLength S 15 5 INZ(%size(QCmdCmd))
*--------------------------------------------------------------*
C if (Lib = ' ')
c eval Lib = '*LIBL'
c endIF
C eval QCmdCmd = 'OVRDBF FILE' +
C '(QHTMLSRC) ' +
C 'TOFILE(' +
C %TRIM(LIB) + '/' +
C %TRIM(FILE) +
C ') MBR(' +
C %TRIM(SRCMBR) + ')'
C CALL 'QCMDEXC'
C PARM QCmdCmd
C PARM QCmdLength
c open QHTMLSRC
C READ QHTMLSRC
C DOW (NOT *IN69)
C EVAL POS = %scan('?userid="':SRCDTA)
c if POS = *zero
C eval wrtdta = srcdta + newline
c else
C eval pos = pos + 7
C eval pos2 = pos + 1
C eval wrtdta = %subst(srcdta:1:pos) +
C %trim(USERID) +
C %subst(srcdta:pos2) +
C
c endif
c callp #wrstout(wrtdta)
C READ QHTMLSRC
c endDO
c CLOSE QHTMLSRC
*-----------------------------------------------
P #WrtSrcMbr E
FQHTMLSRC IF E DISK USROPN RENAME(QHTMLSRC:HTMLSRC)
D #WrtSrcMbr PR
D PR_Lib 10 VALUE
D PR_File 10 VALUE
D PR_SrcMbr 10 VALUE
HTH some more.
Mark
-----Original Message-----
From: web400-admin@midrange.com [mailto:web400-admin@midrange.com]On
Behalf Of Justin Houchin
Sent: Wednesday, April 24, 2002 6:38 AM
To: web400@midrange.com
Subject: Re: [WEB400] Writing Source Member to Web Page
I have created the text file Qhtmlsrc. But my subprocedure gets a
compilation error because it doesn't see the text file external description.
Is there some way of compiling the text file??
This mailing list archive is Copyright 1997-2026 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.