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.
Locked
User avatar
InBoise
Posts: 16
Joined: Tue Aug 01, 2017 8:57 am

DateTimePicker Format

Post by InBoise » Fri Apr 13, 2018 1:10 pm

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

User avatar
cody m
Site Admin
Posts: 123
Joined: Thu Jun 01, 2017 7:20 am

Re: DateTimePicker Format

Post by cody m » Fri Apr 13, 2018 1:21 pm

[TOPIC MOVED BY MODERATOR]
Cody McCants
SAPIEN Technologies, Inc.

User avatar
jvierra
Posts: 12953
Joined: Tue May 22, 2007 9:57 am
Contact:

Re: DateTimePicker Format

Post by jvierra » Fri Apr 13, 2018 1:31 pm

$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

Locked