Solved

Powershell Windows.Forms.DateTimePicker - Date only?

Posted on 2014-11-20
2
1,293 Views
Last Modified: 2014-11-20
I am working with a Windows.Forms.DateTimePicker in a Powershell GUI.

I can pick the date and return the value, but the problem is it is returning the time as well.
How can I get it to just be the value of the date (like "11/20/2014" instead of "11/21/2014 11:45:18 AM"?
0
Comment
Question by:garryshape
2 Comments
 
LVL 40

Accepted Solution

by:
Subsun earned 500 total points
ID: 40455840
You could format the value. For example..
$DatePicker.value.ToString("MM/dd/yyyy")
0
 

Author Closing Comment

by:garryshape
ID: 40455906
sweet it works thanks so much
0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

Are you one of those front-line IT Service Desk staff fielding calls, replying to emails, all-the-while working to resolve end-user technological nightmares? I am! That's why I have put together this brief overview of tools and techniques I use in o…
Microsoft Windows Server Update Service (WSUS) is free for everyone, but it lacks of some desirable features like send an e-mail to the administrator with the status of all computers on the WSUS server. This article is based on my PowerShell script …
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now