B2C business-to-consumer is now popular with "B 2 C "...... Bold Innovation! Commendable
For developers: browser compatibility is a headache. Because the division of labor is clear, we seldom touch htmlCodeBut when there is no UED, you only have to work hard on your head.
I fell down here yesterday! It's done now!
Firefox, chrome, Safari, IE8, opera ...... Test OK. The problem lies in IE6 and 7. No way to use IE6, 7 occupies half of Domestic user browsers.
What we want
At the beginning, the general framework is drawn on the ASPX page, and the dynamic generation of CS also meets the needs. Different browsers are available for testing. Style issues occur. Except IE6 and 7, all the other browsers I mentioned above are OK.
I found the problem only in the morning after a long time in the afternoon. I thought it was not shown later. I did not know it after reading it carefully. It was wrong! The textfield (red box) in the back goes to the front ......
If you have any questions, take a break or lose one side first. The answer is usually popped up at this time. This idea suddenly occurred when I went to work in the morning. Each textfiled control is placed in the cell under tablelayout. Although controls can be placed directly in cells, why not put a Panel first and then controls ......
Ext. net. Panel cell1panel =New Ext. net. Panel () {border = False , Padding = 10 , Layout = " Tablelayout " }; // User information panel
Tablelayout cell1paneltablelayout = New Tablelayout {columns = column, rowheight = 0.8 };
Cell cell;
Datarow [] drlist;
Cell cellline;
Ext. net. Panel panelline;
Ext. net. Panel panelcell; // Add a panel to place the component item control on the panel before placing the panel on the cell.
# Region Fill in user information form
For ( Int I = 0 ; I <strucgroupsettable. Rows. Count; I ++) //
{
Drlist = fieldtable. Select ( " Isshow = 1 and pnlfuid =' " + Pnlfuid + " 'And groupfuid =' " + Strucgroupsettable. Rows [I] [ " Fuid " ]. Tostring () + " And fieldtype <> 'image' " , " Controlorderno " );
For (Int J = 0 ; J <drlist. length; j ++)
{
Cell = New Cell ();
Panelcell = New Ext. net. Panel () {border = False , Autoheight = True , Padding = 2 };
If (J = drlist. Length- 1 )
Cell. colspan = column;
Component item = createcontrols. getcontrols (drlist [J], sourcedatatable. Rows [ 0 ] [Drlist [J] [ " Fieldalias " ]. Tostring ()], isreadonly );
If (J <drlist. Length- 1 )
{
If (Drlist [J + 1 ] [ " Controltype " ]. Tostring (). tolower () = " Tfmdbmemo " | Drlist [J + 1 ] [ " Controltype " ]. Tostring (). tolower () = " Tcxdbmemo " )
{
Cell. colspan = column;
If (Drlist [J] [ " Controltype " ]. Tostring (). tolower () = " Tfmdbmemo " | Drlist [J] [ " Controltype " ]. Tostring (). tolower () = " Tcxdbmemo " )
{
Item. width = 460 ;
}
}
}
Else
{
If (Drlist [J] [ " Controltype " ]. Tostring (). tolower () = " Tfmdbmemo " | Drlist [J] [ " Controltype " ]. Tostring (). tolower () = " Tcxdbmemo " )
{
Cell. colspan = column;
Item. width = 460 ;
}
}
Panelcell. width = unit. parse (item. Width. Value + 20 ). Tostring ());
Panelcell. Items. Add (item );
Cell. Items. Add (panelcell );
Cell1paneltablelayout. cells. Add (cell );
}
If (I <strucgroupsettable. Rows. Count- 1 ) // Draw line
{
Cellline = New Cell () {colspan = column };
Panelline = New Ext. net. Panel () {Height =1 , Width = 480 };
Cellline. Items. Add (panelline );
Cell1paneltablelayout. cells. Add (cellline );
}
}
Cell1panel. Items. Add (cell1paneltablelayout );
Laydeskpanel_table_cell1.items.add (cell1panel );
Lay?panel_table.cells.add (lay?panel_table_cell1 );
# Endregion
(The disadvantage is to set the length and width)
The CS generated for the page will not be pasted out, and everyone has their own architecture method. Now let's take a look at the improvements we have set up.
Common progress
If you encounter this problem, try adding panel and controls to cell.
Author: Pepe
Source: http://pepe.cnblogs.com/
The copyright of this article is shared by the author and the blog. You are welcome to repost this article, but you must keep this statement without the author's consent andArticleThe original text connection is clearly displayed on the page. Otherwise, the legal liability is retained.