SPREAD for ASP.NET 10.0J サンプルコード集 > セル型 > イメージ型セル > イメージのサイズを設定する |
イメージ型セルのCssClassプロパティにスタイルシートを設定します。
ImageCellType imCell = new ImageCellType() { ImageUrl = "~/images/logo.png", CssClass = "myimage" }; FpSpread1.Cells[0, 1].CellType = imCell;
Dim imCell As New ImageCellType() With { .ImageUrl = "~/images/logo.png", .CssClass = "myimage" } FpSpread1.Cells(0, 1).CellType = imCell
<!--スタイルシートでイメージのサイズを設定します--> <style type="text/css"> .myimage img {width:90px; height:71px} </style>