By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,952 Members | 1,665 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,952 IT Pros & Developers. It's quick & easy.

Inherited User Controls [Win C#] going about it the correct way?

P: n/a
Hi everyone,

I posted a question very early today, but maybe I wasn't articulate enough.
Hopefully this will illicit a response

I've created a windows form and a User Control. This is a keyboard. What I
have done is that every keystroke is entered into a textbox within my User
Control. Want I want to do is to take that user input from keyboard textbox
and display it within my main form. I also want to be able to close this
control and not having it on my application unless it is being called again.
Now, the only way I can figure a way around this is to create an Inherited
User Control, then call the Inherited User Control. But by doing this I
cannot (I think) use the regular way of obtaining data from a user control
with Delegates etc, because the control is not hook to the main form. I am
also very dumb-founded in how to close this Inherited User Control.

Am I going about this the correct way? In not, how should I be going about
this. If I am going about this the correct way, then how do I get around my
problems of closing the Inherited User control, and passing data from the
control?

My Syntax for calling the keyboard is as follows:

HOST.I_Ctrl_KeyBoard myKeyBoard= new HOST.I_Ctrl_KeyBoard();
myKeyBoard.Location = new System.Drawing.Point(275, 305);

myKeyBoard.Parent = this;
myKeyBoard.BringToFront();
myKeyBoard.Show();

Any and all help is truly appreciated txs and sorry for the re-post.

MikeY

May 17 '06 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.