•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the Pascal and Delphi section within the Software Development category of DaniWeb, a massive community of 422,405 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 4,898 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our Pascal and Delphi advertiser: Programming Forums
Views: 499 | Replies: 3
![]() |
| |
•
•
Join Date: May 2008
Posts: 2
Reputation:
Rep Power: 0
Solved Threads: 0
Hey all,
I'm currently writing a program that will do various things with dates. The problem that I currently have is getting pascal to recognise dates in various formats (eg. 24/09/93 or 09-03-04 or 17 01 99, etc) when input by a user. This data needs to be read by pascal in a way that allows me to alter the output (ie. the date written out in full).
Any suggestions/solutions would be immensely appreciated.
I'm currently writing a program that will do various things with dates. The problem that I currently have is getting pascal to recognise dates in various formats (eg. 24/09/93 or 09-03-04 or 17 01 99, etc) when input by a user. This data needs to be read by pascal in a way that allows me to alter the output (ie. the date written out in full).
Any suggestions/solutions would be immensely appreciated.
•
•
Join Date: Oct 2007
Location: Cherry Hill, NJ
Posts: 1,875
Reputation:
Rep Power: 11
Solved Threads: 193
Take a look through this thread:
Tutorial: Handling Dates and Time in Delphi
Near the bottom there is some thoughts on reading dates (which is the hard part). Writing dates is easy.
Hope this helps.
Tutorial: Handling Dates and Time in Delphi
Near the bottom there is some thoughts on reading dates (which is the hard part). Writing dates is easy.
Hope this helps.
•
•
Join Date: May 2008
Posts: 2
Reputation:
Rep Power: 0
Solved Threads: 0
Thanks for the link/ help, Duoas. I've never used Delphi before, and although I can see the similiarities, I'm generally new to the programming game so I'm having some trouble understanding it.
If you have any words of wisdom in the Pascal programming language, that would be very useful indeed. Thanks again.
If you have any words of wisdom in the Pascal programming language, that would be very useful indeed. Thanks again.
•
•
Join Date: Oct 2007
Location: Cherry Hill, NJ
Posts: 1,875
Reputation:
Rep Power: 11
Solved Threads: 193
Heh, glad to have helped.
I know it takes a while to get your head around it, but the only way it will come is to struggle along... alas. But it will come, don't worry.
One of the most overlooked features in Delphi (IMHO) is the use of try...except blocks in data transformation. In simple terms, endeavor to do things one way. If the input doesn't match, raise an exception and catch that to try another way. Keep going until you either run out of ways to try or until the input matches.
Good luck.
I know it takes a while to get your head around it, but the only way it will come is to struggle along... alas. But it will come, don't worry.
One of the most overlooked features in Delphi (IMHO) is the use of try...except blocks in data transformation. In simple terms, endeavor to do things one way. If the input doesn't match, raise an exception and catch that to try another way. Keep going until you either run out of ways to try or until the input matches.
Good luck.
![]() |
•
•
•
•
•
•
•
•
DaniWeb Pascal and Delphi Marketplace
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
Similar Threads
- Need Help With Printing Pascal's Triangle In C (C)
- CIS or CS degree question?? (Computer Science and Software Design)
- Turbo pascal homework (Pascal and Delphi)
- School assignment in pascal (Pascal and Delphi)
- 12 hrs later (Geeks' Lounge)
- Pseudo-Pascal Question: Need Help!! (Pascal and Delphi)
Other Threads in the Pascal and Delphi Forum
- Previous Thread: Simple problem...
- Next Thread: using method or dereferenced object pointer



Hybrid Mode