Click here to Skip to main content
15,886,026 members
Home / Discussions / Windows Forms
   

Windows Forms

 
QuestionValues on Form 2 appears on Form 1 !?? c# Pin
Phoenix_p326-Nov-07 9:03
Phoenix_p326-Nov-07 9:03 
AnswerRe: Values on Form 2 appears on Form 1 !?? c# Pin
Pete O'Hanlon26-Nov-07 10:43
mvePete O'Hanlon26-Nov-07 10:43 
GeneralRe: Values on Form 2 appears on Form 1 !?? c# Pin
Christian Graus26-Nov-07 11:44
protectorChristian Graus26-Nov-07 11:44 
GeneralRe: Values on Form 2 appears on Form 1 !?? c# Pin
Pete O'Hanlon26-Nov-07 21:58
mvePete O'Hanlon26-Nov-07 21:58 
GeneralRe: Values on Form 2 appears on Form 1 !?? c# Pin
Christian Graus27-Nov-07 0:08
protectorChristian Graus27-Nov-07 0:08 
GeneralRe: Values on Form 2 appears on Form 1 !?? c# Pin
Pete O'Hanlon27-Nov-07 5:16
mvePete O'Hanlon27-Nov-07 5:16 
QuestionDataGrid Component for Window Forms alike of in ASP.Net 1.0 Pin
WinSolution24-Nov-07 6:34
WinSolution24-Nov-07 6:34 
QuestionRetaining Focus in owned Forms Pin
TyrionTheImp24-Nov-07 3:32
TyrionTheImp24-Nov-07 3:32 
Hi ,

I`ve just hit an interesting roadblock in my app & would really appreciate any help / feedback. The "bug" can be replicated easily.

Basically, I have 2 forms running as 2 different processes , say Form X & Form Y.
Their properties are :
Form X : ShowinTaskbar = true , FixedToolWindow , Maximized.
Form Y : Showintaskbar = false , Borderstyle.None , Normal

We have methods on Form Y that can be invoked via Remoting to do Show(owner) , usually Form X ends up being the owner here. I`ve impleneted the IWin32Window interface and initialise it with my Form X`s handle (obtained via FindWindow)

The issue is that Form Y can NEVER retain focus (say when u click on a text box in it) and focus always gets transferred to the owner Form X. I`m not really setting an Owner / Owned relationship between them formally, say , via AddOwnedForms in Form X or Form.Owner = FormX since i guess this doesnt work across processes.

If we change the ShowInTaskbar property of Form X to false , or Form Y to true then there is no problem with the Focus.

Can someone please suggest where i`m going wrong or if theres any other action i need to do ? I dont really understand how the ShowinTaskbar property is affecting the focus mechanism , or whether this is how windows itself works.

So far i`ve tried doing a Activate() , Focus() & BringtoFront() in Form Y but it doesnt work.

SetParent isnt an option since it couples together their lifetimes i.e. if child crashes parent also crashes.

Thanks in advance
AnswerRe: Retaining Focus in owned Forms Pin
Xmen Real 24-Nov-07 4:11
professional Xmen Real 24-Nov-07 4:11 
GeneralRe: Retaining Focus in owned Forms Pin
TyrionTheImp25-Nov-07 20:07
TyrionTheImp25-Nov-07 20:07 
GeneralRe: Retaining Focus in owned Forms Pin
Xmen Real 25-Nov-07 21:20
professional Xmen Real 25-Nov-07 21:20 
GeneralRe: Retaining Focus in owned Forms Pin
TyrionTheImp27-Nov-07 17:21
TyrionTheImp27-Nov-07 17:21 
GeneralRe: Retaining Focus in owned Forms Pin
Xmen Real 27-Nov-07 18:29
professional Xmen Real 27-Nov-07 18:29 
QuestionHow to chane title bar of a window form in C# Pin
WinSolution23-Nov-07 9:04
WinSolution23-Nov-07 9:04 
AnswerRe: How to chane title bar of a window form in C# Pin
Kristian Sixhøj23-Nov-07 9:08
Kristian Sixhøj23-Nov-07 9:08 
GeneralRe: How to chane title bar of a window form in C# Pin
WinSolution23-Nov-07 9:19
WinSolution23-Nov-07 9:19 
GeneralRe: How to chane title bar of a window form in C# [modified] Pin
Kristian Sixhøj23-Nov-07 9:31
Kristian Sixhøj23-Nov-07 9:31 
GeneralRe: How to chane title bar of a window form in C# Pin
WinSolution23-Nov-07 9:53
WinSolution23-Nov-07 9:53 
GeneralRe: How to chane title bar of a window form in C# Pin
Kristian Sixhøj23-Nov-07 10:07
Kristian Sixhøj23-Nov-07 10:07 
GeneralRe: How to chane title bar of a window form in C# Pin
Xmen Real 24-Nov-07 3:57
professional Xmen Real 24-Nov-07 3:57 
Questionwindows forms (windows application with c#) Pin
avvaru.murali23-Nov-07 1:16
avvaru.murali23-Nov-07 1:16 
QuestionPrint datagridview data in pdf page Pin
kiran@p2softech22-Nov-07 18:14
kiran@p2softech22-Nov-07 18:14 
AnswerRe: Print datagridview data in pdf page Pin
Xmen Real 24-Nov-07 4:00
professional Xmen Real 24-Nov-07 4:00 
QuestionHow to resize a form? Pin
daavena22-Nov-07 9:34
daavena22-Nov-07 9:34 
AnswerRe: How to resize a form? Pin
superda23-Nov-07 0:32
superda23-Nov-07 0:32 

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.