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

C#

 
Questioncreating events for dynamically created button Pin
Member 1126181115-Aug-15 0:48
Member 1126181115-Aug-15 0:48 
AnswerRe: creating events for dynamically created button Pin
OriginalGriff15-Aug-15 1:19
mveOriginalGriff15-Aug-15 1:19 
Since you create a number of textboxes (which is probably a poor idea - have a look at a DataGridView or similar instead, it does most of the work for you) you will have to search for them (or use the inputTextBoxes collection you added them to).

Searching is relatively simple - they are in the form Controls array along with all the others - but I'd just look in your collection! Just move it to a private class level variable and access it in your Click event handler.
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...

AnswerRe: creating events for dynamically created button Pin
BillWoodruff15-Aug-15 2:58
professionalBillWoodruff15-Aug-15 2:58 
QuestionTimeSpan Error?? Pin
Kevin Marois14-Aug-15 12:16
professionalKevin Marois14-Aug-15 12:16 
AnswerRe: TimeSpan Error?? Pin
Matt T Heffron14-Aug-15 14:16
professionalMatt T Heffron14-Aug-15 14:16 
GeneralRe: TimeSpan Error?? Pin
Kevin Marois17-Aug-15 3:59
professionalKevin Marois17-Aug-15 3:59 
GeneralRe: TimeSpan Error?? Pin
Pete O'Hanlon17-Aug-15 4:24
mvePete O'Hanlon17-Aug-15 4:24 
GeneralRe: TimeSpan Error?? Pin
Kevin Marois17-Aug-15 4:28
professionalKevin Marois17-Aug-15 4:28 
GeneralRe: TimeSpan Error?? Pin
Ravi Bhavnani17-Aug-15 5:12
professionalRavi Bhavnani17-Aug-15 5:12 
GeneralRe: TimeSpan Error?? Pin
Pete O'Hanlon17-Aug-15 5:15
mvePete O'Hanlon17-Aug-15 5:15 
GeneralRe: TimeSpan Error?? Pin
Kevin Marois17-Aug-15 5:24
professionalKevin Marois17-Aug-15 5:24 
GeneralRe: TimeSpan Error?? Pin
Dr. John L. Aven31-Aug-15 17:16
Dr. John L. Aven31-Aug-15 17:16 
GeneralRe: TimeSpan Error?? Pin
Ravi Bhavnani17-Aug-15 5:24
professionalRavi Bhavnani17-Aug-15 5:24 
GeneralRe: TimeSpan Error?? Pin
Kevin Marois17-Aug-15 5:25
professionalKevin Marois17-Aug-15 5:25 
GeneralRe: TimeSpan Error?? Pin
Ravi Bhavnani17-Aug-15 5:35
professionalRavi Bhavnani17-Aug-15 5:35 
GeneralRe: TimeSpan Error?? Pin
Matt T Heffron17-Aug-15 6:55
professionalMatt T Heffron17-Aug-15 6:55 
GeneralRe: TimeSpan Error?? Pin
Richard Deeming17-Aug-15 7:10
mveRichard Deeming17-Aug-15 7:10 
QuestionWhy don't I see a VSTO template Pin
Gary Huck14-Aug-15 9:47
Gary Huck14-Aug-15 9:47 
AnswerRe: Why don't I see a VSTO template Pin
Richard MacCutchan14-Aug-15 20:49
mveRichard MacCutchan14-Aug-15 20:49 
Question(Solved) How to send a message from a rich text box control to a form Pin
Leif Simon Goodwin14-Aug-15 0:56
Leif Simon Goodwin14-Aug-15 0:56 
AnswerRe: How to send a message from a rich text box control to a form Pin
Arthur V. Ratz14-Aug-15 2:08
professionalArthur V. Ratz14-Aug-15 2:08 
SuggestionRe: How to send a message from a rich text box control to a form Pin
Richard Deeming14-Aug-15 3:18
mveRichard Deeming14-Aug-15 3:18 
GeneralRe: How to send a message from a rich text box control to a form Pin
Leif Simon Goodwin14-Aug-15 3:27
Leif Simon Goodwin14-Aug-15 3:27 
GeneralRe: How to send a message from a rich text box control to a form Pin
Arthur V. Ratz14-Aug-15 3:36
professionalArthur V. Ratz14-Aug-15 3:36 
GeneralRe: How to send a message from a rich text box control to a form Pin
Arthur V. Ratz14-Aug-15 3:30
professionalArthur V. Ratz14-Aug-15 3:30 

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.