DateTimePicker Format

Ask questions about creating Graphical User Interfaces (GUI) in PowerShell and using WinForms controls.
Forum rules
Do not post any licensing information in this forum.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
This topic is 5 years and 11 months old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
Locked
User avatar
InBoise
Posts: 17
Last visit: Thu Nov 23, 2023 4:20 pm

DateTimePicker Format

Post by InBoise »

To help you better we need some information from you.

*** Please fill in the fields below. If you leave fields empty or specify 'latest' rather than the actual version your answer will be delayed as we will be forced to ask you for this information. ***

Product, version and build:Powershell Studio 2018
32 or 64 bit version of product:64
Operating system:Windows 10
32 or 64 bit OS:64

*** Please add details and screenshots as needed below. ***
From the DateTimePicker object is there a way to get just the date without the time in format where the month is spelled out, not a number. (i.e. April 13, 2018) as a string Thanks
cody m

Re: DateTimePicker Format

Post by cody m »

[TOPIC MOVED BY MODERATOR]
jvierra
Posts: 15439
Last visit: Tue Nov 21, 2023 6:37 pm
Answers: 30
Has voted: 4 times
Been upvoted: 33 times

Re: DateTimePicker Format

Post by jvierra »

$datetimepicker1.Value.ToLongDateString()

For all controls use the context menu on the control in the toolbox to access the documentation.

There is a link to almost all online MSDN documentation for each control.

https://msdn.microsoft.com/en-us/librar ... icker.aspx
This topic is 5 years and 11 months old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
Locked