コード例 #1
0
    protected void CreateTable(PlaceHolder placeHolder, DataRow[] rows, int width, int height)
    {
        placeHolder.Controls.Clear();
        Table t = new Table();

        placeHolder.Controls.Add(t);
        for (int i = 0; i < rows.Length; i++)
        {
            Contact contact = ContactDB.LoadAll(rows[i]);
            if (contact.FreeText.Trim().Length > 0)
            {
                t.Rows.Add(CreateNewRow(contact, width, height, true, true));
                t.Rows.Add(CreateNewRow(contact, width, height, true, false));
            }
            else
            {
                t.Rows.Add(CreateNewRow(contact, width, height, false, false));
            }
        }
    }