Normando Chaile 20 Reputation points

Hola, quería ver si me podrían ayudar a guardar la fecha seleccionada en un DateTimePicker en una variable?

An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,501 questions
{count} votes

Accepted answer
  1. Minxin Yu 10,466 Reputation points Microsoft Vendor

    Hi, @Normando Chaile

    You can use ValueChanged event.

            System.DateTime DT;
            private void dateTimePicker1_ValueChanged(object sender, EventArgs e)
               DT = dateTimePicker1.Value;

    Best regards,

    Minxin Yu

    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

0 additional answers

Sort by: Most helpful