开发者

How to use MVC Contrib Grid to make better table?

There are actually 2 question i want to cover in this topic.

1) Is there anyway to put table footer into a MVCContrib Grid? (tf)

2) Im writing a small code to display result image into a grid:

-----------------------------------
| I || I || I || I || I || I || I |
-------------------------开发者_运维知识库----------
| I || I || I || I || I || I || I |
-----------------------------------
| I || I || I || I || I || I || I |
-----------------------------------
| I || I || I || I || I || I || I |
-----------------------------------

I represent Image, this will make as a table to maintain equal width.. But is there anyway of doing this with MVCCOntrib particularly or Asp.net MVC View?

Thank you


For item #1:

Out of the box there’s no built in way to do this, but there are some extensibility points you can hook into if you want to add this functionality.

If you create a custom GridRenderer that inherits from HtmlTableGridRender then you could override the RenderGridEnd method and generate the appropriate HTML in there. - Jeremey Skinner

From comments in http://www.jeremyskinner.co.uk/2009/03/01/mvccontrib-grid-part-5-the-action-syntax/

On #2:

As long as you wrap your images in a way with styling to enforce the same size for each image (if the images are of different sizes to begin with) this should be doable.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜