|
-
Feb 17th, 2010, 09:08 AM
#1
Thread Starter
New Member
Convert string to date in VB6
Hi all,
I am very new to VB6 and have something I can't seem to figure out. Help would be greatly appreciated!!!!
I have a field stored in the database as varchar6 in the yyyymm format. I need to add 18 months to this date and display the results on a vb6 form. Can someone help me with the code to do this?
Thank you in advance for you help.
Christine
-
Feb 17th, 2010, 09:14 AM
#2
Re: Convert string to date in VB6
VB's DateSerial can do the trick, using Left 4 chars as the year, Right 2 chars as the month, then supply 1 for the day. Use VB's DateAdd() function to add to a date variable as desired.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|