South African Public Holidays
Forums
Hi There
I need some assistance to write an IDEAScript to identify all transactions that occur on South African Public holidays. The date of the holiday never changes. Ideally the script must allow the user to select the file to test and then column that holds the date. Then the script must run and extract all those records that were processed on the following dates:
1 January
21 March
29 March
1 April
27 April
1 May
16 June
17 June
9 August
24 September
16 December
25 December
26 December
Please can someone assist me.
Thank you in advance.
Aveen
Extract Dates
Hi Aveen,
Can you try this script out and give me any comments. When you run it you will have the following dialog:
From the above menu you would select the file and the date field. If you have previously created the dates you can load them in by hitting the Load Dates button. I have attached a list of all your dates below so you can load those in. The dates will appear in the bottom of the dialog, you can have up to 24 dates.
If you hit the Edit Dates button you would have the following dialog:
You can add dates in the above dialog or load dates previously saved and edit them. Also you can add dates and save them for reuse in the future. The dates must be in the format DDMM and it won't accept Feb 29 as a date.
Let me know if you have any problems or comments with it. I will probably add it to the scripting section later on.
Update for Version 8.5
Hi Aveen, I found the problem and have updated the script to work in version 8.5. It is attached above. I also added on two other things based on comments from a friend who tried it out last night. I have added the text file name to the main dialog and also added an option to extract all dates except for those listed.
Let me know if you have any problems or comments on how to imporve the script.
I think you will have to talk
I think you will have to talk to your distributor about the updates and/or a demo version. If you watch the videos that are online they were all done with V9 so that can give you an idea of what it looks like.
Great to hear that the script works!! It would always be interesting if you want to talk about how you are using the script in real scenario.
thanks
Brian, your scripting information is really helpful and the videos are excellent.
Please keep adding more scripting videos e.g. how IDEAScript and VisualScript can work together, or how/why to create an executable.
Scripting is not that well documentated in IDEA so every little bit of info helps, particularly about the bugs.
Identify dates
Hi Aveen, that sounds like an interesting project. I will see what I can come up with.