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



Hello Jonathan,

Not I - I didn't write it. I'm just stuck trying to clean up the mess.
This is some kind of shareware/freeware stuff that developers at my
employer obtained long before I arrived there.

Oh, sorry... I got the impression that you (or maybe David Foxwell) were the developer who was creating a shareware/freeware application for e-mail.

After all, David asked whether it made sense to replace QWCRSSTS with RTVNETA. That sure sounds like a question that would be asked by the developer... since the developer is the one writing the code... right?

Anyway... the answer is: NEITHER.

If you are trying to derive the logged in user's e-mail address, 'username@xxxxxxxxxxxxxxxxxxxxxx' then you should probably be retrieving the SMTP name for your user from the system distribution directory. there's no reason to assume that a user's e-mail address points to the current system!

If you want to know your computer's TCP/IP name, then you should be using the gethostname() API. I'd be happy to give you an RPG or CL example of this if it's useful to you.

Using RTVNETA or QWCRSSTS to get the 'systemname' portion of 'systemname.company.net' is not a proper way to do it.

For example, I could set up my system's name as follows:

CHGNETA SYSNAME(FOO)

And it could set up it's TCP/IP domain name as follows:

CHGTCPDMN HOSTNAME('bar') DMNNAME('company.net')

If I did that, and someone used either QWCRSSTS or RTVNETA to get the 'systemname', they'd arrive at 'scott@xxxxxxxxxxxxxxx' which wouldn't point to my system, since my system is 'scott@xxxxxxxxxxxxxxx'

The existing code makes an assumption that whomever configured the system always set the CHGNETA SYSNAME(x) to the same value as CHGTCPDMN HOSTNAME(x). IMHO, that's not a valid assumption. These are two different settings, and it's perfectly legal to make them different.

I'm just posting this to try to help people understand.

I realize it's not your software and you don't like it. But since David asked the question about whether to use the API or the command, I thought it'd be useful to explain it.

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.