wpftoolkit icon indicating copy to clipboard operation
wpftoolkit copied to clipboard

With DateTimePicker Can't Access PART_TextBox

Open shelbypo opened this issue 2 years ago • 2 comments

Hello, I trying to access the PART_TextBox, So when I click the tab button on the date to go next date part gets null.

shelbypo avatar Nov 06 '23 18:11 shelbypo

这里是郭瑞的邮箱,已收到您的来件,我会尽快拜阅并给予您回复

zhongruijia avatar Nov 06 '23 18:11 zhongruijia

Hello, you can always create your own DateTimePicker and retrieve the PART_TextBox control from OnApplyTemplate(): ` public class MyDateTimePicker : DateTimePicker { public override void OnApplyTemplate() { base.OnApplyTemplate();

 var textBox = this.GetTemplateChild( "PART_TextBox" ) as TextBox;

} }`

XceedBoucherS avatar Nov 07 '23 12:11 XceedBoucherS