From the course: Visual Basic Essential Training

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Solution: Strings, dates, and parsing

Solution: Strings, dates, and parsing - Visual Basic Tutorial

From the course: Visual Basic Essential Training

Start my 1-month free trial

Solution: Strings, dates, and parsing

(upbeat music) - [Instructor] I hope you had fun working on this challenge. Here's my results. Remember, your solution may be different from mine. I implemented mine as a WPF application with three text boxes: one for entering the date, one for entering the interval, and one for showing the output. If you click on this button now, you'll see the results. If you attempt to enter an invalid number for the interval, you'll get this 'Cannot parse the interval'. Same thing with the date. Now let's look at the results with correct values for an interval and date. I'm outputting some strings. The original date is Friday, November 14, 2025. This line tells you how many days and months we're going to add: five, and this one shows the 'Calculated End Date': April 19, 2026. And of course this is interactive, so you can type in your values like that. Also go take a look at the code solution. You'll start out by declaring…

Contents