Click here to Skip to main content
15,903,523 members
Home / Discussions / C#
   

C#

 
QuestionDataGridView Data Filtering Pin
freshonlineMax10-Mar-07 21:19
freshonlineMax10-Mar-07 21:19 
AnswerRe: DataGridView Data Filtering Pin
il_masacratore12-Mar-07 2:47
il_masacratore12-Mar-07 2:47 
QuestionScroll Problem Pin
MHASSANF10-Mar-07 19:34
MHASSANF10-Mar-07 19:34 
AnswerRe: Scroll Problem Pin
sam#10-Mar-07 19:50
sam#10-Mar-07 19:50 
QuestionRe: Scroll Problem Pin
MHASSANF10-Mar-07 21:24
MHASSANF10-Mar-07 21:24 
AnswerRe: Scroll Problem Pin
sam#10-Mar-07 23:25
sam#10-Mar-07 23:25 
AnswerRe: Scroll Problem Pin
Dave Kreskowiak11-Mar-07 4:36
mveDave Kreskowiak11-Mar-07 4:36 
QuestionLoop Pin
shamsteady10-Mar-07 17:25
shamsteady10-Mar-07 17:25 
I had write this code


for (int i = 0; i < totalEquipment; i++)


try

{
for (int j = 0; j < sEquip[index].index; j++)
{
try
{
...
bar[j].Size = new Size(length,20);
bar[j].BackColor = System.Drawing.Color.Blue;
bar[j].Location = new Point(xPosition,yPosition);
this.Controls.Add(bar[j]);
...
}

catch (Exception ex)
{
throw new Exception(ex.Message + " " + ex.StackTrace);
}
finally
{
xPosition += length;
}
}
}
catch (Exception ex)
{
throw new Exception(ex.Message + " " + ex.StackTrace);
}

finally
{
yPosition -= range;
}

}
}

The problem is this part which it keep add panel to window form without stoping like non stop looping. How can i stop this error?

try
{
...
bar[j].Size = new Size(length,20);
bar[j].BackColor = System.Drawing.Color.Blue;
bar[j].Location = new Point(xPosition,yPosition);
this.Controls.Add(bar[j]);
...
}
AnswerRe: Loop Pin
Guffa10-Mar-07 18:09
Guffa10-Mar-07 18:09 
GeneralRe: Loop Pin
shamsteady10-Mar-07 18:17
shamsteady10-Mar-07 18:17 
AnswerRe: Loop Pin
Christian Graus10-Mar-07 19:40
protectorChristian Graus10-Mar-07 19:40 
QuestionDES Encryption Pin
Ravun10-Mar-07 16:47
Ravun10-Mar-07 16:47 
AnswerRe: DES Encryption Pin
Dominik Reichl11-Mar-07 3:21
Dominik Reichl11-Mar-07 3:21 
GeneralRe: DES Encryption Pin
Ravun11-Mar-07 12:28
Ravun11-Mar-07 12:28 
QuestionTrail of Tears Part 2 (i.e. Control Locations)... Pin
new_phoenix10-Mar-07 12:11
new_phoenix10-Mar-07 12:11 
AnswerRe: Trail of Tears Part 2 (i.e. Control Locations)... Pin
M-Hall10-Mar-07 13:03
M-Hall10-Mar-07 13:03 
GeneralRe: Trail of Tears Part 2 (i.e. Control Locations)... Pin
Guffa10-Mar-07 13:33
Guffa10-Mar-07 13:33 
QuestionWallpaper Pin
CodeItWell10-Mar-07 11:04
CodeItWell10-Mar-07 11:04 
AnswerRe: Wallpaper Pin
Dawid Mazuruk10-Mar-07 23:36
Dawid Mazuruk10-Mar-07 23:36 
QuestionArray Pin
shamsteady10-Mar-07 9:23
shamsteady10-Mar-07 9:23 
AnswerRe: Array Pin
Travis D. Mathison10-Mar-07 9:59
Travis D. Mathison10-Mar-07 9:59 
GeneralRe: Array Pin
shamsteady10-Mar-07 10:02
shamsteady10-Mar-07 10:02 
GeneralRe: Array Pin
Christian Graus10-Mar-07 10:30
protectorChristian Graus10-Mar-07 10:30 
QuestionDifferences between strings Pin
tzuiop10-Mar-07 5:51
tzuiop10-Mar-07 5:51 
AnswerRe: Differences between strings Pin
Christian Graus10-Mar-07 5:57
protectorChristian Graus10-Mar-07 5:57 

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.