Click here to Skip to main content
15,905,144 members
Home / Discussions / C#
   

C#

 
QuestionHelp CrystalReport Pin
KppsK20-Oct-07 12:08
KppsK20-Oct-07 12:08 
QuestionD vs C# Pin
Mike717120-Oct-07 11:08
Mike717120-Oct-07 11:08 
AnswerRe: D vs C# Pin
Christian Graus20-Oct-07 12:47
protectorChristian Graus20-Oct-07 12:47 
GeneralRe: D vs C# Pin
Mike717120-Oct-07 14:28
Mike717120-Oct-07 14:28 
GeneralRe: D vs C# Pin
Christian Graus20-Oct-07 14:37
protectorChristian Graus20-Oct-07 14:37 
AnswerRe: D vs C# Pin
PIEBALDconsult21-Oct-07 12:39
mvePIEBALDconsult21-Oct-07 12:39 
QuestionTextBox.Name Pin
j_sen20-Oct-07 8:56
j_sen20-Oct-07 8:56 
AnswerRe: TextBox.Name Pin
Luc Pattyn20-Oct-07 9:17
sitebuilderLuc Pattyn20-Oct-07 9:17 
j_sen wrote:
TextBox txtBox = new TextBox();
txtBox.Name = readIn;
txtBox.Text = "Why wont this work";


So you create a new TextBox, give it a name and some text.
Fine.
This has nothing to do with other TextBoxes that may already exist.
It will not magically point to an existing TextBox with the selected name!

If you want to set the text of MyFirstTextBox, the one direct way to do this is
by MyFirstTextBox.Text="new text";

If you want to modify one of many existing Controls, you either need:
1. a lot of code (one piece for each Control), say a switch
2. or a Dictionary that maps names onto Controls
3. or Reflection

Smile | :)



Luc Pattyn [Forum Guidelines] [My Articles]


this months tips:
- use PRE tags to preserve formatting when showing multi-line code snippets
- before you ask a question here, search CodeProject, then Google


GeneralRe: TextBox.Name Pin
Guffa20-Oct-07 9:27
Guffa20-Oct-07 9:27 
GeneralRe: TextBox.Name Pin
Luc Pattyn20-Oct-07 12:14
sitebuilderLuc Pattyn20-Oct-07 12:14 
AnswerRe: TextBox.Name Pin
Guffa20-Oct-07 9:26
Guffa20-Oct-07 9:26 
QuestionHow to add visio shapes into Win Forms using C#? Pin
Pooya Musavi20-Oct-07 3:56
Pooya Musavi20-Oct-07 3:56 
AnswerRe: How to add visio shapes into Win Forms using C#? Pin
Giorgi Dalakishvili20-Oct-07 4:37
mentorGiorgi Dalakishvili20-Oct-07 4:37 
QuestionSplash Screen in C# for Beginners - Intermediate Pin
andyr200520-Oct-07 2:22
andyr200520-Oct-07 2:22 
AnswerRe: Splash Screen in C# for Beginners - Intermediate Pin
Luc Pattyn20-Oct-07 2:27
sitebuilderLuc Pattyn20-Oct-07 2:27 
GeneralRe: Splash Screen in C# for Beginners - Intermediate Pin
Uwe Keim20-Oct-07 3:48
sitebuilderUwe Keim20-Oct-07 3:48 
GeneralRe: Splash Screen in C# for Beginners - Intermediate Pin
Luc Pattyn20-Oct-07 5:15
sitebuilderLuc Pattyn20-Oct-07 5:15 
GeneralRe: Splash Screen in C# for Beginners - Intermediate Pin
Uwe Keim20-Oct-07 6:26
sitebuilderUwe Keim20-Oct-07 6:26 
AnswerRe: Splash Screen in C# for Beginners - Intermediate Pin
Christian Graus20-Oct-07 14:39
protectorChristian Graus20-Oct-07 14:39 
QuestionRe: Splash Screen in C# for Beginners - Intermediate Pin
andyr200520-Oct-07 23:05
andyr200520-Oct-07 23:05 
AnswerRe: Splash Screen in C# for Beginners - Intermediate Pin
Tobias Schoenig21-Oct-07 19:25
Tobias Schoenig21-Oct-07 19:25 
Questionaccept only numbers Pin
kabutar20-Oct-07 2:09
kabutar20-Oct-07 2:09 
AnswerRe: accept only numbers Pin
Giorgi Dalakishvili20-Oct-07 2:15
mentorGiorgi Dalakishvili20-Oct-07 2:15 
GeneralRe: accept only numbers Pin
kabutar20-Oct-07 2:18
kabutar20-Oct-07 2:18 
GeneralRe: accept only numbers Pin
Giorgi Dalakishvili20-Oct-07 2:22
mentorGiorgi Dalakishvili20-Oct-07 2:22 

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.