× 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.




I don't have any experience with this API but I think I can infer
something from your e-mail.

Given the logic at the end of your post it sounds like you are making
the call to the API after writing the last record to the subfile. The
call is returning a no record found error. That makes sense. If you
are trying to set attributes for record numbers after the last one
written there is no record for the API to work on. This is the same
behavior one would expect using the RPG op-codes to write records to a
subfile and then access them. If you try and access a record number not
in the subfile you get a record not found error.

HTH,

Rick

-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Ganesh Kumar
Murugesan
Sent: Monday, April 21, 2008 2:48 AM
To: rpg400-l@xxxxxxxxxxxx
Subject: Subfile API QdtsSetDspAtrSF - Set subfile display attributes

I'm trying to develop an utility to edit the contents of a data area and
the layout of this utility's screen would be similar to DSPDTAARA
screen, but with an editable field. If the length of the data area is
not divisible by 50, then I need protect (and nondisplay) the remaining
extra length of the last record displayed on the subfile.

To do this, I tried using QdtsSetDspAtrSF API but I'm getting a value of
-1 in the return code, which means "record not found". My RRN value is
correct and the record is present but I'm not sure why Iam getting this
error. I tried to refer to some examples of this API but unfortunately I
couldn't find anything via google. If anyone has a working example of
this API, please share it with me. I have also used QdtsInitSF to
initialize the user space in QTEMP in my *INZST subroutine and I can see
the userspace in QTEMP.


Here is my logic,

DOW loop to write records into the subfile.
1) Increment RRN by 1
2) If it is the last record, then call API QdtsSetDspAtrSF to protect
and nondisplay the remaining area of the subfile field.
3) Write Subfile
ENDDO


I have also tried to write the subfile record first for the particular
RRN before calling the API (interchanging step 2 & 3) and still it
didn't work.

Thanks in advance.

Privileged and Confidential. This e-mail, and any attachments there to, is intended only for use by the addressee(s) named herein and may contain privileged or confidential information. If you have received this e-mail in error, please notify me immediately by a return e-mail and delete this e-mail. You are hereby notified that any dissemination, distribution or copying of this e-mail and/or any attachments thereto, is strictly prohibited.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

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.