Click here to Skip to main content
15,911,531 members
Home / Discussions / C#
   

C#

 
QuestionRe: How to redirect user after the form data is submitted? Pin
CWIZO18-Jan-06 7:17
CWIZO18-Jan-06 7:17 
AnswerRe: How to redirect user after the form data is submitted? Pin
Sue_NC18-Jan-06 7:27
Sue_NC18-Jan-06 7:27 
GeneralRe: How to redirect user after the form data is submitted? Pin
Sue_NC18-Jan-06 7:51
Sue_NC18-Jan-06 7:51 
GeneralRe: How to redirect user after the form data is submitted? Pin
DeepToot18-Jan-06 8:27
DeepToot18-Jan-06 8:27 
QuestionCopy format and all from Word Document Pin
DeepToot18-Jan-06 6:34
DeepToot18-Jan-06 6:34 
AnswerRe: Copy format and all from Word Document Pin
Dave Kreskowiak18-Jan-06 15:57
mveDave Kreskowiak18-Jan-06 15:57 
GeneralRe: Copy format and all from Word Document Pin
DeepToot19-Jan-06 2:35
DeepToot19-Jan-06 2:35 
QuestionForcing the dotted focus box on a button? Pin
melanieab18-Jan-06 5:34
melanieab18-Jan-06 5:34 
Hi,
Before I go into detail, is there any way to force a button to get that dotted box on it that shows it's in focus? Just saying btn1.Focus(); isn't working for me. Btn1 is definitely the thing being focused on, but you wouldn't know by just looking at it. And it seems that the only way to get a button to show highlight is to Tab into it.

So, the weird details... D'Oh! | :doh:
Say I put a custom button on my form (and gave it tabstop 1). I then add a textbox with tabstop 2. And finally another button (tabstop 3). If I click in the textbox and press the Tab key, the 2nd button gets that dotted line, no problem. Same goes if I press Shift-Tab (the 1st button shows focus). I made the textbox so that it recognizes if the up or down keys are hit, so when I'm in the textbox and press the up key, I say:
if (e.KeyCode == Keys.Up){SendKeys.Send("+{Tab}");}
and have no problem here either - the first button shows focus.
But if down is pressed:
if (e.KeyCode == Keys.Down){SendKeys.Send("{Tab}");}
it freaks out and everything freezes so that I have to open task manager to close it down.

One other thing - if a button has been highlighted (tabbed into) once, saying just btn1.Focus(); is enough. But, of course, I can't be sure that tab will always be pressed.
Hope this makes sense.
Thanks for any help on this!
Mel
AnswerRe: Forcing the dotted focus box on a button? Pin
melanieab18-Jan-06 9:50
melanieab18-Jan-06 9:50 
AnswerRe: Forcing the dotted focus box on a button? Pin
microsoc18-Jan-06 14:50
microsoc18-Jan-06 14:50 
Questionbuilding a Binary Tree Class Pin
nickmacon18-Jan-06 5:30
nickmacon18-Jan-06 5:30 
AnswerRe: building a Binary Tree Class Pin
Pablo Hernandez Valdes18-Jan-06 6:16
Pablo Hernandez Valdes18-Jan-06 6:16 
QuestionExport treeview to xml Pin
Insolence18-Jan-06 5:15
Insolence18-Jan-06 5:15 
AnswerRe: Export treeview to xml Pin
zopiro18-Jan-06 11:51
zopiro18-Jan-06 11:51 
GeneralRe: Export treeview to xml Pin
Insolence18-Jan-06 14:00
Insolence18-Jan-06 14:00 
QuestionHow can I raise an event from a DLL's worker thread? Pin
Todd Beaulieu18-Jan-06 5:05
Todd Beaulieu18-Jan-06 5:05 
QuestionCrystal Reports with C# Pin
idreesbadshah18-Jan-06 3:29
idreesbadshah18-Jan-06 3:29 
Questionhow can i stop flickering on the form Pin
ugurbil18-Jan-06 2:45
ugurbil18-Jan-06 2:45 
AnswerRe: how can i stop flickering on the form Pin
Judah Gabriel Himango18-Jan-06 4:38
sponsorJudah Gabriel Himango18-Jan-06 4:38 
GeneralRe: how can i stop flickering on the form Pin
ugurbil18-Jan-06 6:06
ugurbil18-Jan-06 6:06 
QuestionRichTextBox Question Please Help!!!!! Pin
snouto18-Jan-06 2:27
snouto18-Jan-06 2:27 
AnswerRe: RichTextBox Question Please Help!!!!! Pin
Judah Gabriel Himango18-Jan-06 4:45
sponsorJudah Gabriel Himango18-Jan-06 4:45 
QuestionTreeView Nodes Pin
Gamil Mohamad18-Jan-06 1:44
Gamil Mohamad18-Jan-06 1:44 
AnswerRe: TreeView Nodes Pin
Judah Gabriel Himango18-Jan-06 4:49
sponsorJudah Gabriel Himango18-Jan-06 4:49 
GeneralRe: TreeView Nodes Pin
Gamil Mohamad19-Jan-06 22:00
Gamil Mohamad19-Jan-06 22:00 

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.