zoukankan      html  css  js  c++  java
  • WPF 中Devexpress GridControl无限高度问题

    今天在用WPF开发时,调用DevExpress的GridControl。测试时正常,但最后转到所需要的框架出了问题,报错如下:

    By default, an infinite grid height is not allowed since all grid rows will be rendered and, hence, the grid will work very slowly. To fix this issue, place the grid into a container that will give a finite height to the grid, or manually specify the grid's Height or MaxHeight. Note that you can also avoid this exception by setting the GridControl.AllowInfiniteGridSize static property to True, but in that case, the grid will run slowly.

    我的英语也是个半罐水,翻译后才知道。是页面的Grid的Height为星号或者Atuo时,就会报这个错!

    网上查的资料都说得。。。。。不说了伤心。

    现在我用最简单的方法:

      直接把GridControl.View下添加一个MaxHeight就行了

    <dxg:GridControl.View>
    <dxg:TableView AllowPerPixelScrolling="True" ShowTotalSummary="True" ShowGroupPanel="False" GroupSummaryDisplayMode="AlignByColumns" AllowColumnFiltering="False" AllowResizing="True" MaxHeight="600"/>
    </dxg:GridControl.View>

    这个MaxHeight根据自己的实际情况添加

  • 相关阅读:
    Java calendar类学习笔记
    Anaconda 学习笔记
    第八周作业
    第七次作业
    第六周作业
    第五次作业
    用户调研方法之焦点小组
    第三周作业
    软件工作量的评估方法有哪些
    软件质量保证与测试(--作业--)
  • 原文地址:https://www.cnblogs.com/icewatermei/p/14423379.html
Copyright © 2011-2022 走看看