Validation

Please support our C# advertiser: Intel Parallel Studio Home
Thread Solved

Join Date: Oct 2008
Posts: 1,909
Reputation: ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of ddanbe has much to be proud of 
Solved Threads: 274
ddanbe's Avatar
ddanbe ddanbe is offline Offline
Posting Virtuoso

Re: Validation

 
0
  #11
Mar 4th, 2009
Originally Posted by Raskahil Fol
Why do you do this? This is not C. Predeclaration
I know this is an old habbit I got from my Modula-2 times.
Thanks for reminding me.
Today is a gift, that's why it is called "The Present".
Make love, no war. Cave ab homine unius libri.
Danny
Reply With Quote Quick reply to this message  
Join Date: Mar 2009
Posts: 24
Reputation: foxypj is an unknown quantity at this point 
Solved Threads: 0
foxypj foxypj is offline Offline
Newbie Poster

Re: Validation

 
0
  #12
Mar 4th, 2009
That works well and outputs as

12 December, 1990

Which is great now all i need to do is make the program work out whether the day needs a th, nd, rd, st and make that output with the date.


i.e. the date should eventually output;

12th December 1990.
Reply With Quote Quick reply to this message  
Join Date: Aug 2008
Posts: 1,735
Reputation: LizR has a spectacular aura about LizR has a spectacular aura about 
Solved Threads: 186
LizR LizR is offline Offline
Posting Virtuoso

Re: Validation

 
0
  #13
Mar 4th, 2009
Take a read of the helpfile, there are many date/time formats, its very simple, but you should start reading for yourself what options you have.
Did I just hear "You gotta help us, Doc. We've tried nothin' and we're all out of ideas" ? Is this you? Dont let this be you! I will put in as much effort as you seem to.
Reply With Quote Quick reply to this message  
Join Date: Mar 2009
Posts: 24
Reputation: foxypj is an unknown quantity at this point 
Solved Threads: 0
foxypj foxypj is offline Offline
Newbie Poster

Re: Validation

 
0
  #14
Mar 4th, 2009
Originally Posted by LizR View Post
Take a read of the helpfile, there are many date/time formats, its very simple, but you should start reading for yourself what options you have.
There is no default format to output in this way, hence why i am asking here.
Reply With Quote Quick reply to this message  
Join Date: Aug 2008
Posts: 1,735
Reputation: LizR has a spectacular aura about LizR has a spectacular aura about 
Solved Threads: 186
LizR LizR is offline Offline
Posting Virtuoso

Re: Validation

 
0
  #15
Mar 5th, 2009
So you didnt look.
and before you say you did..

I typed

DateTime.ToString("dd mm yyyy");
placed cursor on ToString
Pressed F1

Got help
Clicked on the datetime format string stuff

http://msdn.microsoft.com/en-us/library/az4se3k1.aspx

which has a second link to

http://msdn.microsoft.com/en-us/library/8kb3ddd4.aspx

You are just plain lazy
Did I just hear "You gotta help us, Doc. We've tried nothin' and we're all out of ideas" ? Is this you? Dont let this be you! I will put in as much effort as you seem to.
Reply With Quote Quick reply to this message  
Join Date: Mar 2009
Posts: 24
Reputation: foxypj is an unknown quantity at this point 
Solved Threads: 0
foxypj foxypj is offline Offline
Newbie Poster

Re: Validation

 
0
  #16
Mar 5th, 2009
Originally Posted by LizR View Post
So you didnt look.
and before you say you did..

I typed

DateTime.ToString("dd mm yyyy");
placed cursor on ToString
Pressed F1

Got help
Clicked on the datetime format string stuff

http://msdn.microsoft.com/en-us/library/az4se3k1.aspx

which has a second link to

http://msdn.microsoft.com/en-us/library/8kb3ddd4.aspx

You are just plain lazy
i have to chuckle at that. I did look at this site. Please go ahead and highlight the part that tells me how to add th, nd, st, rd on the end of the day?

yes i can add 3 april, 2009 which i could already do. Go ahead and tell me how to add the rest of it. There is no default coding in C# that has that effect and no coding in that help file.

After looking carefully through the internet carefully. it seems the only way to do it is to write and array that uses mathematics to work out which day needs which suffix. i am struggling with this writing such an array.

I have had some very good help from others on this site maybe they will help me.
Reply With Quote Quick reply to this message  
Join Date: Aug 2008
Posts: 1,735
Reputation: LizR has a spectacular aura about LizR has a spectacular aura about 
Solved Threads: 186
LizR LizR is offline Offline
Posting Virtuoso

Re: Validation

 
0
  #17
Mar 5th, 2009
It gets really tiring to see people who dont try and then expect others here to do the work. I know theres no date format that does the suffix, which is why I got you to look. If you google there are plenty of functions out there prewritten you can use to do it.

I too know theres no built in function to do it, it seems kind of a large oversight IMHO, but, there isnt. However, like most things like this, someone already has hit this and written something to do it. I got back a lot of hits with sensible code from google.
Did I just hear "You gotta help us, Doc. We've tried nothin' and we're all out of ideas" ? Is this you? Dont let this be you! I will put in as much effort as you seem to.
Reply With Quote Quick reply to this message  
Join Date: Mar 2009
Posts: 24
Reputation: foxypj is an unknown quantity at this point 
Solved Threads: 0
foxypj foxypj is offline Offline
Newbie Poster

Re: Validation

 
0
  #18
Mar 5th, 2009
Originally Posted by LizR View Post
It gets really tiring to see people who dont try and then expect others here to do the work. I know theres no date format that does the suffix, which is why I got you to look. If you google there are plenty of functions out there prewritten you can use to do it.

I too know theres no built in function to do it, it seems kind of a large oversight IMHO, but, there isnt. However, like most things like this, someone already has hit this and written something to do it. I got back a lot of hits with sensible code from google.
Yes of course you can google it. I have done this already. and yes i agree that it is a large oversight.

i apologise for the outburst at you. Just rather frustrated with the coding, and finding it awfully difficult. please accept my apologese. i am sorry that you feel like i have not tried. i think that is an unfair assumption on me. however that is something i will not discuss as you have no right to judge me in that.

i will have another look at google and hopefully this time i can understand some of the codes that i get hit with. i am sorry that what seemed like a lovely site at first has ended up making me feel pretty down about my coding.

cheers then

Foxypj
Reply With Quote Quick reply to this message  
Join Date: Aug 2007
Posts: 111
Reputation: ChaseVoid is an unknown quantity at this point 
Solved Threads: 12
ChaseVoid's Avatar
ChaseVoid ChaseVoid is offline Offline
Junior Poster

Re: Validation

 
0
  #19
Mar 5th, 2009
You don't need to feel down. It's just that people tend to get irritated and fed up with those who just come around here looking for ready answers. I'm sure you must have tried, but you didn't write anything about it. If you are stuck somewhere ask for help on that part and people here will gladly correct you.

I hope you don't go away from the forum. Give us some of your trials and we'll help you out the best we can. Do you really think it's fair for us, who has the answer to give it those who nothing of it. it'll not only make us fell uncomfortable to help but also harms those who doesn't try out.

Hope you understand.
Reply With Quote Quick reply to this message  
Join Date: Mar 2009
Posts: 24
Reputation: foxypj is an unknown quantity at this point 
Solved Threads: 0
foxypj foxypj is offline Offline
Newbie Poster

Re: Validation

 
0
  #20
Mar 6th, 2009
Originally Posted by ChaseVoid View Post
You don't need to feel down. It's just that people tend to get irritated and fed up with those who just come around here looking for ready answers. I'm sure you must have tried, but you didn't write anything about it. If you are stuck somewhere ask for help on that part and people here will gladly correct you.

I hope you don't go away from the forum. Give us some of your trials and we'll help you out the best we can. Do you really think it's fair for us, who has the answer to give it those who nothing of it. it'll not only make us fell uncomfortable to help but also harms those who doesn't try out.

Hope you understand.
Thank you to everyone who has helped me. I have finally solved this program. Liz my sincere apologies for my outbursts.

The help here has been awesome from everybody. Thank you.

foxypj
Reply With Quote Quick reply to this message  
Reply

This thread has been marked solved.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the C# Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC