|
-
Jun 15th, 2009, 03:29 PM
#1
Thread Starter
New Member
Help with .ToString
Hi guys,
Basically I have just started to learn about pogramming in a general sense and with Visual Basic as i need an understanding of programming for uni when i start next year.
Now im reading through the visual basic 2008 for dummies book and im trying to follow their example but ive hit a problem and i cant see or no why.
Heres the code:
Public Class Form1
Private Sub DateTimePicker1_ValueChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles DateChooser.ValueChanged
NextWeek.Text = DateChooser.Value.AddDays(7)).ToString()
End Sub
End Class
The problem lies where i have ended the 6th line in ").ToString()"
It comes up with a caption saying end of statement expected but i cant find any solution for the love of money.
As i said i am a very beginner so please be patient with me as i'm just trying to learn like everyone else 
Thanks in advance
-
Jun 15th, 2009, 05:21 PM
#2
Re: Help with .ToString
You have an extra bracket, it should be:
vb.net Code:
NextWeek.Text = DateChooser.Value.AddDays(7).ToString()
EDIT:
Just noticed this is a duplicate thread: http://www.vbforums.com/showthread.php?t=573059
Last edited by ForumAccount; Jun 15th, 2009 at 05:31 PM.
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
|