× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Rick,

A few years ago, before I switched to cgidev2 I used net.data a lot, but
when I was using it, I found this group of net.data articles extremely
useful, when it came to passing tables, and parms, to and from net.data to
rpg.

http://www.web400.com/download.html

hth, tim


-----Original Message-----
From: web400-bounces@xxxxxxxxxxxx [mailto:web400-bounces@xxxxxxxxxxxx] On
Behalf Of rick baird
Sent: Wednesday, July 19, 2006 5:05 PM
To: Web Enabling the AS400 / iSeries
Subject: Re: [WEB400] net.data DTW_DIRECTCALL error.

Mike,

INT is for integer.  the rest, I think I have fixed via Tim H's post,
but I appreciate the help just the same

All the examples in the manuals only showed the declaration of the
function, not the invocation - that's where I got screwed up.

cheers,

Rick

On 7/19/06, Mike Eovino <meovino@xxxxxxxxx> wrote:
Rick,

A couple of problems:

1.  Is INT a valid description for a parameter?  I thought they were
limited to IN, OUT and INOUT.

2.  You don't have datatypes and field lengths for your parms.  I
don't know if they are required for the program you're calling or not.
 I always use them for RPG and CL.

3.  Don't put your %FUNCTION block inside your %HTML block.  I don't
know that they will work in there.  The manual says the following
about the context for %FUNCTIONs:

Context
The FUNCTION block can be found in these contexts:
- IF block
- Outside of any block or statement in the declaration part of the
Net.Data
macro.


On 7/19/06, rick baird <rick.baird@xxxxxxxxx> wrote:
hey all,

I'm trying to get a DTW_DIRECTCALL function for net.data working, and
i'm having a dickens of a time.  could someone check my syntax please?

the error I'm getting on the page is:

%function(DTW_DIRECTCALL) dc1( IN psession, OUT pstatus, INT pstore,
INT pfyear, INT pfper ) { %EXEC { IRTGETPARM.PGM NET.DATA Error: An
incorrect symbol (%}) was encountered at line 29 of file
/HTTP/WEBT/NETDATA/phy/irt/irtmenu.mac.

see the code below:

line 29 is the line directly after the %EXEC { IRTGETPARM.PGM  %}

the cookie is being set, and it is also being retrieved, action and
session are being passed as url query string variables

I'm pulling my hair out here - been screwing around with this for about
3 hours.

Thanks!
----------
%include "inc.define"
%include "inc.runsql"

%html(main) {

%if($(action) == "new")
 @DTW_SETCOOKIE("sns_irt_session_id", $(session), "expires=Friday,
10-Nov-2050 00:00:00;path=/")
%endif

@DTW_GETCOOKIE("sns_irt_session_id", psession)

%IF($(RETURN_CODE) == "8000")
 <html>
 <body>
 <br><br>
  IRT Session has not been established or has expired.<br><br>
     Please close this window and restart the application.<br>
  </body>
</html>
%ENDIF

%function(DTW_DIRECTCALL) dc1( IN psession,
                              OUT pstatus,
                                  INT pstore,
                                  INT pfyear,
                                  INT pfper  ) {
 %EXEC { IRTGETPARM.PGM  %}
%}

%IF($(PSTATUS) == "N")
 <html>
 <body>
 <br><br>
  IRT Session has not been established or has expired.<br><br>
     Please close this window and restart the application.<br>
 </body>
</html>
 @DTW_EXIT()
%ENDIF

<html>
<head>
 <title>$(IRTapp) - Main Menu</title>
 <link rel="stylesheet" href="/phy/htm/style1.CSS" type="text/css">
</head>

<body>

...etc. etc.

------------
the include files are used elsewhere and don't have any errors.
--
This is the Web Enabling the AS400 / iSeries (WEB400) mailing list
To post a message email: WEB400@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/web400
or email: WEB400-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/web400.


--
This is the Web Enabling the AS400 / iSeries (WEB400) mailing list
To post a message email: WEB400@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/web400
or email: WEB400-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/web400.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 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.