Click here to Skip to main content
15,893,588 members
Home / Discussions / C#
   

C#

 
GeneralRe: Urgent Pin
Keith Barrow4-Aug-10 21:15
professionalKeith Barrow4-Aug-10 21:15 
GeneralRe: Urgent Pin
Abhinav S4-Aug-10 22:51
Abhinav S4-Aug-10 22:51 
QuestionHelp me figure out a Generic Dictionary problem for a game! [modified] Pin
venomation4-Aug-10 13:02
venomation4-Aug-10 13:02 
AnswerRe: Help me figure out a Generic Dictionary problem for a game! Pin
venomation4-Aug-10 14:02
venomation4-Aug-10 14:02 
Question"Not enough storage is available to process this command" Pin
Alan Balkany4-Aug-10 11:05
Alan Balkany4-Aug-10 11:05 
AnswerRe: "Not enough storage is available to process this command" Pin
Yusuf4-Aug-10 11:10
Yusuf4-Aug-10 11:10 
AnswerSOLVED. Pin
Alan Balkany5-Aug-10 5:10
Alan Balkany5-Aug-10 5:10 
Questionevent handling on object in a container from a dll [solved] Pin
Louis-Etienne Chicoine4-Aug-10 10:08
Louis-Etienne Chicoine4-Aug-10 10:08 
OK i have made a DLL with only one accessible function. It returns a panel with a label in it.

In the dll there's also an event handler for mousemouve. It needs to change the label to display the mouse position on the panel.

My problem is that i need everything done on the side of the DLL. The main program is only there to place the panel on a form and must not deal with event handling from the panel.

here's what i got for the dll

namespace PanelClass
{
public class ConstPanel
{
public Panel FabPan(int x, int y)
{
Panel P = new Panel();
Label L = new Label();
L.Left = 1;
L.Top = 1;
L.Text = "allo";
P.Height = y;
P.Width = x;
P.BorderStyle = BorderStyle.FixedSingle;
P.Controls.Add(L);
P.MouseMove += new MouseEventHandler(P_MouseMove);
return P;
}
void P_MouseMove(object sender, MouseEventArgs e)
{
//needs to change the text in label L
}
}
}

and the main application

private void button1_Click(object sender, EventArgs e)
{
PanelClass.ConstPanel P = new ConstPanel();
Panel Pan = P.FabPan(100, 100,1);
this.Controls.Add(Pan);
}


So what should i do

thanks for your time
modified on Thursday, August 5, 2010 8:41 AM

AnswerRe: event handling on object in a container from a dll Pin
Luc Pattyn4-Aug-10 11:17
sitebuilderLuc Pattyn4-Aug-10 11:17 
QuestionRegex and Split() usage Pin
JoeSchmoe0074-Aug-10 9:05
JoeSchmoe0074-Aug-10 9:05 
AnswerRe: Regex and Split() usage Pin
Ennis Ray Lynch, Jr.4-Aug-10 9:26
Ennis Ray Lynch, Jr.4-Aug-10 9:26 
GeneralRe: Regex and Split() usage Pin
JoeSchmoe0074-Aug-10 9:28
JoeSchmoe0074-Aug-10 9:28 
GeneralRe: Regex and Split() usage Pin
T M Gray4-Aug-10 9:54
T M Gray4-Aug-10 9:54 
AnswerRe: Regex and Split() usage Pin
T M Gray4-Aug-10 9:42
T M Gray4-Aug-10 9:42 
GeneralRe: Regex and Split() usage Pin
JoeSchmoe0074-Aug-10 9:50
JoeSchmoe0074-Aug-10 9:50 
AnswerRe: Regex and Split() usage Pin
Anurag Gandhi4-Aug-10 19:56
professionalAnurag Gandhi4-Aug-10 19:56 
AnswerRe: Regex and Split() usage Pin
AspDotNetDev5-Aug-10 11:04
protectorAspDotNetDev5-Aug-10 11:04 
GeneralRe: Regex and Split() usage Pin
JoeSchmoe0075-Aug-10 11:16
JoeSchmoe0075-Aug-10 11:16 
QuestionIllegal characters in path. Pin
Vimalsoft(Pty) Ltd4-Aug-10 3:57
professionalVimalsoft(Pty) Ltd4-Aug-10 3:57 
AnswerRe: Illegal characters in path. Pin
Richard MacCutchan4-Aug-10 6:22
mveRichard MacCutchan4-Aug-10 6:22 
GeneralRe: Illegal characters in path. Pin
Vimalsoft(Pty) Ltd4-Aug-10 8:00
professionalVimalsoft(Pty) Ltd4-Aug-10 8:00 
AnswerRe: Illegal characters in path. Pin
DaveyM694-Aug-10 11:58
professionalDaveyM694-Aug-10 11:58 
QuestionBinding Source Issue Pin
spankyleo1234-Aug-10 2:59
spankyleo1234-Aug-10 2:59 
AnswerRe: Binding Source Issue Pin
Ennis Ray Lynch, Jr.4-Aug-10 5:02
Ennis Ray Lynch, Jr.4-Aug-10 5:02 
GeneralRe: Binding Source Issue Pin
spankyleo1234-Aug-10 5:23
spankyleo1234-Aug-10 5:23 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.