Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 01-30-2015, 01:35 AM
Attila Attila is offline Return Value from DTpicker into DocVariable in Word Windows XP Return Value from DTpicker into DocVariable in Word Office 2010 64bit
Novice
Return Value from DTpicker into DocVariable in Word
 
Join Date: Jan 2015
Posts: 7
Attila is on a distinguished road
Default Return Value from DTpicker into DocVariable in Word

Hello there..

I have several Comboboxes and Textboxes in my UserForm all of them are returning correctly into my DocVariables.
The code I used to return Textbox Value to the Variable is:
ActiveDocument.Variable("var1") = Textbox1.value
I tried now to do the same with the DTPicker
ActiveDocument.Variable("var2") = DTPicker.value
But it returns either 00:00:00 or 30 0000 2015.
I tried to format the DTPicker with the code:
DTPicker = Format(DTPicker,"dd mmmm yyyy")
Also I tried to change the Variable to:


{DocVariable var2 \@ "dd mmmm yyyy"}
Each way didn't work. So please can somebody help me.
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
DocProperty vs DocVariable ChrisBrewster Word VBA 1 02-07-2014 02:09 PM
DocVariable formatting and the ability to truncate a string. MaxInCO Word 1 12-18-2013 05:35 PM
Return Value from DTpicker into DocVariable in Word Calculate the coordinates of a DocVariable, Bookmark or paragraph. MaxInCO Word VBA 5 12-11-2013 03:28 PM
Return Value from DTpicker into DocVariable in Word DTPicker date formatting Andy2011 Word VBA 1 08-24-2012 02:45 PM
Return Value from DTpicker into DocVariable in Word DOCVARIABLE copy paste special cyndor Word 2 04-06-2012 03:57 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 04:43 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft