Search Results

Search found 4 results on 1 pages for 'shiv09'.

Page 1/1 | 1 

  • Accessing elements of List<List<string>>

    - by shiv09
    Hello Friends........... Can anyone let me know how can access an element of a list that has been added to a list of list............. I'll mention the code............ List str = new List(); List stud = new List(); A method has been defined that inserts data into str and after the method gets over......... stud.Add(str); The method and stud.Add(str) is on a button click...... so, each time str contains different data....... the problem is I want to search in whole of stud i.e. all the str created, whether str[0]==textBox3.Text; I'm confused in the For loops...how to reach to all the str[0] in stud to verify the condition...................

    Read the article

  • Adding checkbox dynamically

    - by shiv09
    public Form1 f1 = new Form1(); int p = 150; int q = 100; public void add() { //CheckBox c = new CheckBox(); //c.Location = new Point(p, q); //c.Text = f1.sub[0]; //this.Controls.Add(c); CheckBox chkBox = new CheckBox(); chkBox.Location = new Point(p, q); chkBox.Text = "Checked"; chkBox.Checked = false; chkBox.CheckState = CheckState.Checked; chkBox.CheckedChanged += new EventHandler(chkBox_CheckedChanged);// this.Controls.Add(chkBox); chkBox.Text = f1.sub[1];//The problem is here...whatever value I supply to sub[] it gives the below mentioned error } Index was out of range. Must be non-negative and less than the size of the collection. Parameter name: index Here sub[] is a list in form1 which has 5 values...

    Read the article

  • Access form elements

    - by shiv09
    Hello Friends......I'm creating a multiform application in c#. I'm storing the values from the user in a List in form 1 and I want to access the same stored values of the same list in form 2...I m not able to access the stored values...The error I'm getting indicates that there are no values in the list which I'm accessing from form 2...Please help me out...

    Read the article

  • Create list<string> dynamically

    - by shiv09
    Hello, friends... I want to create a list in a button click event...every time the button is clicked a new list should be created having different name than the previous one... Can anyone please help me out...I'm stuck on it...

    Read the article

1