DB Error: 1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 2

SELECT * FROM `user` the_table WHERE the_table.userid = DB Error: 1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 2

SELECT * FROM `user` the_table WHERE the_table.userid = findingdifference between two datepicker's date in visual basic? - iTechForums
Login
Search   Moderators Wanted: If you're interested please send your portfolio to info[at]itechforums.com
Welcome to the iTechForums.
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.
To register now click here.
Latest Threads
Advertisements
Forum Statistics
Threads:
Posts: 2
Members:
Number of Users Online:
Welcome to our newest member,
Reply
 
Thread Tools Display Modes
  #1  
Old 09-17-2009, 03:38 AM
olive olive is offline
Junior Member
 
Join Date: Sep 2009
Posts: 1
Default

findingdifference between two datepicker's date in visual basic?


findingdifference between two datepicker's date in visual basic?

i need to find the difference of number of days between two date pickers in visual basic
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #2  
Old 09-17-2009, 03:38 AM
Yahoo Qs-Ans Yahoo Qs-Ans is offline
Junior Member
 
Join Date: Sep 2009
Posts: 1
Default

Here you go........
no_of_days = DateDiff(d, DTPicker1.Value, DTPicker2.Value)

Above code is assuming that DTPicker1 is the starting date and DTPicker2 is the ending date...
eg; DTPicker1 = 15/03/2009
DTPicker2 = 20/03/2009

For above eg; the no_of_days will be 5

If DTPicker2 is less than DTPicker1 then you will get a negative answer. You can manipulate this as per your requirement or you can validate the user to select the dates as per your requirement.

Best Wishes Olive !!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Visual Basic.net vs Visual C#.net ? they seem the same in their syntax? MobileRam .Net (ASP.Net, VB.Net, C#) 1 09-17-2009 03:42 AM
does red hat enterprise linux supports microsoft visual studio 2006(visual basic... Sivanesh M Oracle 1 01-08-2009 09:54 PM
How to take input of date from user and insert date in oracle table in visual basic? smile Oracle 0 06-04-2008 03:48 PM
i want to know how to use Visual Basic 6.0 language on Visual Basic 2008.? Nik Visual Basic 1 05-06-2008 12:40 PM
WTH is the difference between Visual Basic and Visual Basic Express...? ACE™ Visual Basic 2 05-06-2008 10:12 AM

Your Ad Here

All times are GMT. The time now is 03:32 AM.