-----------------------------------------------------------

New Message on BDOTNET

-----------------------------------------------------------
From: LovedJohnySmith
Message 4 in Discussion

Oic.. Okay, You can achive this using HTMLTableRow Collection, First You may 
need to create a new row, assign the same value which you need to make a clone 
of the row. You can add the Clone Row at any index using AddAt method. please 
have a look at the following code snippet.       void Page_Load(Object sender, 
EventArgs e) 
      {          // Get the number of rows and columns selected by the user.
         int numrows = Convert.ToInt32(Select1.Value);
         int numcells = Convert.ToInt32(Select2.Value);          // Iterate 
through the rows.
         for (int j=0; j<numrows; j++) 
         {             // Create a new row and add it to the Rows collection.
            HtmlTableRow row = new HtmlTableRow();             // Provide a 
different background color for alternating rows.
            if (j%2 == 1)
               row.BgColor="Gainsboro";             // Iterate through the 
cells of a row.
            for (int i=0; i<numcells; i++) 
            {
               // Create a new cell and add it to the Cells collection.
               HtmlTableCell cell = new HtmlTableCell();
               cell.Controls.Add(new LiteralControl("row " + 
                                                 j.ToString() + 
                                                 ", cell " +
                                                 i.ToString()));
               row.Cells.Add(cell);
            }
            Table1.Rows.Add(row);
         }
      }
      <table id="Table1" 
             CellPadding="5" 
             CellSpacing="0" 
             Border="1" 
             BorderColor="black" 
             runat="server"/>
        
      <hr>
 For more information, Please go through the following URL. 
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/frlrfsystemwebuihtmlcontrolshtmltablerowmemberstopic.asp
   Thanx, Smith

-----------------------------------------------------------

To stop getting this e-mail, or change how often it arrives, go to your E-mail 
Settings.
http://groups.msn.com/bdotnet/_emailsettings.msnw

Need help? If you've forgotten your password, please go to Passport Member 
Services.
http://groups.msn.com/_passportredir.msnw?ppmprop=help

For other questions or feedback, go to our Contact Us page.
http://groups.msn.com/contact

If you do not want to receive future e-mail from this MSN group, or if you 
received this message by mistake, please click the "Remove" link below. On the 
pre-addressed e-mail message that opens, simply click "Send". Your e-mail 
address will be deleted from this group's mailing list.
mailto:[EMAIL PROTECTED]

Reply via email to