TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Ergo Sum
NA
1
0
Disallow entry from numeric keyboard to custom date text box and pass entry to text box
Mar 15 2007 3:59 AM
Can someone help me with custom text box? I want change behavior custom date text box - disallow entry and pass entry from numeric keyboard to a text box. Code below disallow entry, but how I can pass entry? public class myDateTextBox : AMS.TextBox.DateTextBox { protected override bool ProcessDialogKey(Keys keyData) { if (keyData >= Keys.NumPad0 && keyData <= Keys.NumPad9) { base.ProcessDialogKey(keyData); return true; } return base.ProcessDialogKey(keyData); } } I try something like this, but it dosen't work. public class x { // ... myDateTextBox order; TextBox textBox; private void order_KeyDown(object sender, KeyEventArgs e) { if (e.KeyCode >= Keys.NumPad0 && e.KeyCode <= Keys.NumPad9) { textBox.Text = Convert.ToString(e.KeyData); } } } Thanks in advance for any help.
Reply
Answers (
0
)
String and string different?
exe expires within few days