Click here to Skip to main content
15,907,183 members
Home / Discussions / C#
   

C#

 
QuestionC# ASP.NET Printing Puzzle!! Pin
Michael1011-May-07 18:11
Michael1011-May-07 18:11 
AnswerRe: C# ASP.NET Printing Puzzle!! Pin
Christian Graus1-May-07 19:17
protectorChristian Graus1-May-07 19:17 
GeneralRe: C# ASP.NET Printing Puzzle!! Pin
Michael1011-May-07 19:38
Michael1011-May-07 19:38 
QuestionDeserialize an object with XML tags Pin
gsteingr1231-May-07 17:49
gsteingr1231-May-07 17:49 
AnswerRe: Deserialize an object with XML tags Pin
PIEBALDconsult1-May-07 17:55
mvePIEBALDconsult1-May-07 17:55 
AnswerRe: Deserialize an object with XML tags Pin
LongRange.Shooter2-May-07 5:18
LongRange.Shooter2-May-07 5:18 
Questionobject reference not set to an instance of an object Pin
Latheesan1-May-07 16:44
Latheesan1-May-07 16:44 
AnswerRe: object reference not set to an instance of an object Pin
PIEBALDconsult1-May-07 17:08
mvePIEBALDconsult1-May-07 17:08 
GeneralRe: object reference not set to an instance of an object Pin
Latheesan1-May-07 17:23
Latheesan1-May-07 17:23 
GeneralRe: object reference not set to an instance of an object Pin
PIEBALDconsult1-May-07 17:53
mvePIEBALDconsult1-May-07 17:53 
GeneralRe: object reference not set to an instance of an object Pin
Latheesan1-May-07 18:07
Latheesan1-May-07 18:07 
GeneralRe: object reference not set to an instance of an object Pin
PIEBALDconsult1-May-07 18:23
mvePIEBALDconsult1-May-07 18:23 
GeneralRe: object reference not set to an instance of an object Pin
Latheesan1-May-07 18:37
Latheesan1-May-07 18:37 
GeneralRe: object reference not set to an instance of an object Pin
PIEBALDconsult1-May-07 19:08
mvePIEBALDconsult1-May-07 19:08 
GeneralRe: object reference not set to an instance of an object Pin
Christian Graus1-May-07 19:19
protectorChristian Graus1-May-07 19:19 
GeneralRe: object reference not set to an instance of an object Pin
PIEBALDconsult1-May-07 17:57
mvePIEBALDconsult1-May-07 17:57 
GeneralRe: object reference not set to an instance of an object Pin
Latheesan1-May-07 18:02
Latheesan1-May-07 18:02 
GeneralRe: object reference not set to an instance of an object Pin
PIEBALDconsult1-May-07 18:50
mvePIEBALDconsult1-May-07 18:50 
GeneralRe: object reference not set to an instance of an object Pin
Latheesan1-May-07 17:27
Latheesan1-May-07 17:27 
GeneralRe: object reference not set to an instance of an object Pin
Latheesan1-May-07 17:35
Latheesan1-May-07 17:35 
Okay, i made a silly mistake in the for loop, but here's the fixed version of the for loop code:

for (int i = 0; i < tabNumber; i++)<br />
            {<br />
                // Create a new tab<br />
                tabPages[i] = new TabPage();<br />
                tabPages[i].Location = new System.Drawing.Point(4, 22);<br />
                tabPages[i].Name = "tabPage" + i.ToString();<br />
                tabPages[i].Padding = new System.Windows.Forms.Padding(3);<br />
                tabPages[i].Size = new System.Drawing.Size(403, 386);<br />
                tabPages[i].TabIndex = i;<br />
                tabPages[i].Text = "tabPage " + i.ToString();<br />
                tabPages[i].UseVisualStyleBackColor = true;<br />
<br />
                // Create a new RichTextBox inside the tab<br />
                shtb[i] = new SyntaxHighlightingTextBox();<br />
                shtb[i].Name = "shtb" + i.ToString();<br />
                shtb[i].Location = new Point(0, 0);<br />
                shtb[i].Dock = DockStyle.Fill;<br />
<br />
                // Add Tab and RichTextBox Control<br />
                tabPages[i].Controls.Add(shtb[i]);<br />
                tabControl.Controls.Add(tabPages[i]);<br />
                <br />
                // Reset of tabControl<br />
                tabPages[i].SuspendLayout();<br />
                tabPages[i].ResumeLayout(false);<br />
                int counter = tabControl.Controls.Count;<br />
                tabControl.SelectedIndex = counter - 1;<br />
                this.Text = "TabText1 - " + tabPages[i].Text;<br />
            }


This compiles correctly, yet, when i run it, i get the exception error again...
QuestionControl Customization/ New User Controls? Pin
Rocky#1-May-07 15:53
Rocky#1-May-07 15:53 
AnswerRe: Control Customization/ New User Controls? Pin
Christian Graus1-May-07 19:21
protectorChristian Graus1-May-07 19:21 
GeneralRe: Control Customization/ New User Controls? Pin
Rocky#4-May-07 8:56
Rocky#4-May-07 8:56 
Questionworking with VarBinary type field (SQL 2000) in C# 2.0 Pin
Rocky#1-May-07 15:46
Rocky#1-May-07 15:46 
AnswerRe: working with VarBinary type field (SQL 2000) in C# 2.0 Pin
PIEBALDconsult1-May-07 18:58
mvePIEBALDconsult1-May-07 18:58 

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.