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



To resolve the issue of having to append 0x00 to your string, just add OPTION(*STRING) to the prototype.

I don't know why you might be having problems with reading a value you set - could be a multitude of things - but like Scott, I would recommend the putenv() and getenv() APIs.

QSH CMD('set > /tmp/my-set.txt')

And

QSH CMD('env > /tmp/my-env.txt')

Might reveal something interesting. (?)


"Bradley Stone" <bvstone@xxxxxxxxx> wrote:

I've been playing around with the envinronment variable APIs to set
the CLASSPATH for java.

At first I started using QtmhPutEnv and QtmhGetEnv, and it worked
fine. But, I realized to use these you'd need to have The HTTP server
installed.

So I did some searching and I found Bob Cozzi's examples for
Qp0zPutEnv and Qp0zGetEnv.

At first the the get wasn't working and I found if I but X'00' after
the classpath name to retrieve, then it worked.

The put was working fine, just like the Qtmh API. A WRKENVVAR command
showed this.

But, I now find that with identical CLASSPATH environment variables,
when set using the Qp0z APIs, it's like the environment variable
doesn't even exist. It can't find the java objects to use and I get
class not found errors when running the same java methods.

If I switch back to using the Qtmh APIs (and sign off and sign back
on), it works slick. I've double checked the class path value and
everything is identical...

Any ideas?

Brad
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.

--
Sent from my Galaxy tablet phone with with K-9 Mail. Please excuse my brevity.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
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.