Adding number of days to date in userform textbox

Capt_Antihero

New Member
Joined
Jun 16, 2014
Messages
14
Hello,

I have a really simple problem that I need help with regarding dates on my userform.

TextBox1 = a date (which I need in mm/dd/yyyy format)
TextBox2 = a number (30 as an example - this is number of days)
Textbox3 = the date in Textbox1 + the number in Textbox2

So textbox3 will have a date in the format of mm/dd/yyyy and would be 30 days in advance of the date listed in textbox1

I'm not a novice so I'm frustrated that I can't get this to work - please help!
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
Hello yes I have tried that, all that was doing was putting the numbers together, so when I had 06/01/2015 in textbox1 and 31 in textbox2 the result in textbox3 was 06/01/201531

I tried using Val(userform1.textbox1.value) + Val(userform1.textbox2.value) and with the same numbers above the result was the number 37 so it was just adding the 06 from the start of the date to the 31
 
Upvote 0

Forum statistics

Threads
1,223,162
Messages
6,170,431
Members
452,326
Latest member
johnshaji

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top