|
I recently published a handful of service programs that interface with a user space. You can check out my approach to user space programming by going to http://mowyourlawn.com and click on the link in the lower right box titled "RPG Dynamic Arrays". I am looking to modify this approach to go off of User Indexes also, but haven't gotten around to that yet. Anyways, all the source is there so you can see exactly what is going on. HTH, Aaron Bartell -----Original Message----- From: rpg400-l-bounces+albartell=gmail.com@xxxxxxxxxxxx [mailto:rpg400-l-bounces+albartell=gmail.com@xxxxxxxxxxxx] On Behalf Of Knezevic.Mihael Sent: Thursday, June 22, 2006 3:46 AM To: RPG programming on the AS400 / iSeries Subject: writing to userspace hello, i got a simple question about writing to a userspace because it is not 100% clear to me. i got a userspace (which is set to autoextend) and in my rpg program i am retrieving a pointer to that userspace. through pointer arithmetic i am filling the userspace with some values. D usPtr S * D usData DS based(usPtr) qualified D header likeds(wws_main_us) D usDataPtr S * D vkst S 5 0 based(usDataPtr) dow (not %eof); usDataPtr = usPtr + %len(usData.header) + (i * %size(vkst)); vkst = someValue; i += 1; read file; enddo; is this the right way to fill a userspace (it seems to be the easiest) ? and is the userspace auto extending when i'm not using the os400 api to write to it? thanx for any answers mihael knezevic -- This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list To post a message email: RPG400-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options, visit: http://lists.midrange.com/mailman/listinfo/rpg400-l or email: RPG400-L-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/rpg400-l.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.