Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 581
  • Last Modified:

Querying QDATFMT from RPG

Any suggestions for obtaining the value of QDATFMT from within an RPG program?
0
bodger
Asked:
bodger
1 Solution
 
peteieCommented:
Have you tried using qcmdexec api to run rtvsysval command?  Another option would be to call a cl program that uses the rtvsysval command and returns the value.

Busy right now but if I get a chance later I'll post some code examples.
peteie
0
 
tliottaCommented:
bodger:

Assuming that you actually need to retrieve the system value itself, the easiest way is probably to create an ILE CL procedure that runs RTVSYSVAL and returns QDATFMT to the caller. Just bind it in with your main RPG procedure.

If that isn't feasible, then the Retrieve System Values (QWCRSVAL) API should be the way to go.

Tom
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now