how to find whether a date format is valid or not in RPG400
not in RPGILE.Can you please write the coding for this sir,i'm
new to AS400.Please help.
Answers were Sorted based on User's Feedback
Answer / katiyar
Select the format of Date (For E.g. *MDY(MMDDYY),
*DMY(DDMMYY) or *USA(MMDDYYYY).....etc and have value in
your variable "YourDate". Verify the date format by coding
as mentioned below.
--------------------RPG---------------------------------
*MDY Test (D) YourDate 99
If *In99 = *On
'Invalid' Dsply
Else
'Valid' Dsply
EndIf
**99 is indicator.
----------------------RPGLE-----------------------------
*MDY Test(DE) YourDate
If %Error
'Invalid' Dsply
Else
'Valid' Dsply
EndIf
---------------------------------------------------------
Is This Answer Correct ? | 6 Yes | 0 No |
what is the necessary keyword needed to scroll subfile records?
What is SFLNXTCHG keyword why it has used and where? Briefly explain with Example.
Delete FileName at first statement in RPG.
wat is the difference between dataarea and data queue?
5 Answers Airtel, Four soft, Shahi Exports,
How can we override a file during runtime in RPG? Without using OVRDBF or calling a CL program
How to search particular records from the database file in rpg?
How to declare the pull button in AS/400..
How to change the name of physical members Dynamically?
Suppose I have 3 jobs a b and c. I want to submit b after successful completion of a and want to submit c after successful completion of b. Without using job scheduler or job queue, how can I do that through cl program?
I have some doubts on subfile----------- -----I wrote a prog on subfile to display the records. Every thing is clear but i defined a field called "opt" as input field in subfile record format from that input field i wish to enter into new screen called "EDIT" which i created it as a separate RCD in display file. i gave opt as 2 for edit just like in WRKMBRPDM screen please telll me the code and how can i code for it in RPG.
what are the key words you must use when using a subfile?
As Packed veriable store 2 digits in 1 byte and ZONE variable store 1 digit in 1 byte... Please tell me when we have to use Packed and Zone variable...?