date problem

Please support our Visual Basic 4 / 5 / 6 advertiser: Programming Forums - DaniWeb Sister Site
Reply

Join Date: Aug 2005
Posts: 4
Reputation: LadyFinger is an unknown quantity at this point 
Solved Threads: 0
LadyFinger LadyFinger is offline Offline
Newbie Poster

date problem

 
0
  #1
Sep 1st, 2005
hi,
my problem is i want to display date using combo box. user will select da date and it will be save to db. da date will be separate to day, month and year. the main prob is i don't know how to aviod this happen 31/2/2005, don't no how 2 xplain....

anyone can help me?
Reply With Quote Quick reply to this message  
Join Date: May 2005
Posts: 514
Reputation: techniner is an unknown quantity at this point 
Solved Threads: 19
techniner techniner is offline Offline
Posting Pro

Re: date problem

 
0
  #2
Sep 1st, 2005
Just setup an input mask or set the field type to a DATE field.

If you mean three sep boxes then thats even easier just say:

Day number must be greater then 0 but less then or = 31 but account for months with 30 days and 28 days etc.

Month > 0 <= 12

Year >= 2005 ??


Not sure what your trying to do exactly.. but its easy to link this up..

You could evn use the CALENDAR option.. popup a calendar let them select a date and populate fields..

or you can fgo the route of... CHOOSE A MONTH

Base don month you get days.... then CHOOSE a Year...

etc etc
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 4
Reputation: LadyFinger is an unknown quantity at this point 
Solved Threads: 0
LadyFinger LadyFinger is offline Offline
Newbie Poster

Re: date problem

 
0
  #3
Sep 1st, 2005
that was gd idea, by pop up the calendar. but how can i link it to a textbox to display the date select by the user? should i use datepicker ? xtually wat is da fn of datepicker? thanks 4 your concern.
Reply With Quote Quick reply to this message  
Join Date: May 2005
Posts: 514
Reputation: techniner is an unknown quantity at this point 
Solved Threads: 19
techniner techniner is offline Offline
Posting Pro
Join Date: Sep 2005
Posts: 1
Reputation: roof is an unknown quantity at this point 
Solved Threads: 0
roof roof is offline Offline
Newbie Poster

Re: date problem

 
0
  #5
Sep 22nd, 2005
Use a calendar for this problem
Reply With Quote Quick reply to this message  
Join Date: Jun 2005
Posts: 121
Reputation: jwshepherd is an unknown quantity at this point 
Solved Threads: 5
jwshepherd's Avatar
jwshepherd jwshepherd is offline Offline
Junior Poster

Re: date problem

 
0
  #6
Sep 24th, 2005
the dtpicker seems to work best for most of my applications.
.: We may acquire liberty, but it is never recovered if it is lost :.
irc://irc.rizon.net/#itf
Reply With Quote Quick reply to this message  
Join Date: Jul 2004
Posts: 200
Reputation: mnemtsas is an unknown quantity at this point 
Solved Threads: 1
mnemtsas's Avatar
mnemtsas mnemtsas is offline Offline
Junior Poster

Re: date problem

 
0
  #7
Sep 27th, 2005
Originally Posted by jwshepherd
the dtpicker seems to work best for most of my applications.
I'll second that.
Reply With Quote Quick reply to this message  
Join Date: Jan 2008
Posts: 3
Reputation: nasir1149 is an unknown quantity at this point 
Solved Threads: 0
nasir1149 nasir1149 is offline Offline
Newbie Poster

Re: date problem

 
0
  #8
Mar 31st, 2008
Can some one help me with the following. Any help will be appriciated.

Platfprm : Visual Studio 2005, Visual Basic

Situation : I have datepicker created in JAVA and call in Visual Basic .net program.

User Pick date and populate to text box.

And click save to SQL 2005 database as date fileld.

My problem is that how to convert date picker date(which is in text box) and save to database

Pls. give me code sample.

NK
Reply With Quote Quick reply to this message  
Join Date: May 2007
Posts: 538
Reputation: choudhuryshouvi is an unknown quantity at this point 
Solved Threads: 49
choudhuryshouvi's Avatar
choudhuryshouvi choudhuryshouvi is offline Offline
Posting Pro

Re: date problem

 
0
  #9
Mar 31st, 2008
Originally Posted by nasir1149 View Post

My problem is that how to convert date picker date(which is in text box) and save to database
use Convert.DateTime(Textbox1.text)

or

CDate(Textbox1.text)
Shouvik_The_Expert_Coder
Have a problem? Don't worry just give me a call and I'll fix it for you.
Reply With Quote Quick reply to this message  
Join Date: Feb 2007
Posts: 2,149
Reputation: debasisdas will become famous soon enough debasisdas will become famous soon enough 
Solved Threads: 132
debasisdas's Avatar
debasisdas debasisdas is offline Offline
Postaholic

Re: date problem

 
0
  #10
Mar 31st, 2008
Originally Posted by nasir1149 View Post
Can some one help me with the following. Any help will be appriciated.

Platfprm : Visual Studio 2005, Visual Basic

...........
..................
........................

NK
Please do not hijack others threads .
Start a thread of your own instead for fresh discussions.
Share your Knowledge.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the Visual Basic 4 / 5 / 6 Forum


Views: 3677 | Replies: 10
Thread Tools Search this Thread



Tag cloud for Visual Basic 4 / 5 / 6
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC