找回密码
 立即注册

QQ登录

只需一步,快速开始

gzgood

中级会员

21

主题

73

帖子

681

积分

中级会员

积分
681

活字格认证

gzgood
中级会员   /  发表于:2016-7-19 13:46  /   查看:3347  /  回复:4
有些用户在对FlexGrid进行新增行操作,然后编辑,会出现以下bug,但不是每次都会出现。
看日志应该是控件报的异常,我想问一下是什么原因造成的,如何解决

全局异常:“-17”不是属性“ViewportSize”的有效值。
   在 System.Windows.DependencyObject.SetValueCommon(DependencyProperty dp, Object value, PropertyMetadata metadata, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType, Boolean isInternal)
   在 System.Windows.DependencyObject.SetValue(DependencyProperty dp, Object value)
   在 C1.WPF.FlexGrid.C1FlexGrid.UpdateScrollBars()
   在 C1.WPF.FlexGrid.C1FlexGrid._gCells_LayoutUpdated(Object sender, EventArgs e)
   在 System.Windows.ContextLayoutManager.fireLayoutUpdateEvent()
   在 System.Windows.ContextLayoutManager.UpdateLayout()
   在 System.Windows.UIElement.UpdateLayout()
   在 System.Windows.Interop.HwndSource.SetLayoutSize()
   在 System.Windows.Interop.HwndSource.set_RootVisualInternal(Visual value)
   在 System.Windows.Interop.HwndSource.set_RootVisual(Visual value)
   在 System.Windows.Controls.Primitives.Popup.SetRootVisualToPopupRoot()
   在 System.Windows.Controls.Primitives.Popup.CreateWindow(Boolean asyncCall)
   在 System.Windows.Controls.Primitives.Popup.OnIsOpenChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
   在 System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs e)
   在 System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e)
   在 System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args)
   在 System.Windows.DependencyObject.UpdateEffectiveValue(EntryIndex entryIndex, DependencyProperty dp, PropertyMetadata metadata, EffectiveValueEntry oldEntry, EffectiveValueEntry& newEntry, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType)
   在 System.Windows.DependencyObject.SetValueCommon(DependencyProperty dp, Object value, PropertyMetadata metadata, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType, Boolean isInternal)
   在 System.Windows.Data.BindingOperations.SetBinding(DependencyObject target, DependencyProperty dp, BindingBase binding)
   在 System.Windows.Controls.Primitives.Popup.CreateRootPopup(Popup popup, UIElement child)
   在 System.Windows.Controls.ToolTip.HookupParentPopup()
   在 System.Windows.Controls.ToolTip.OnIsOpenChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
   在 System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs e)
   在 System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e)
   在 System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args)
   在 System.Windows.DependencyObject.UpdateEffectiveValue(EntryIndex entryIndex, DependencyProperty dp, PropertyMetadata metadata, EffectiveValueEntry oldEntry, EffectiveValueEntry& newEntry, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType)
   在 System.Windows.DependencyObject.SetValueCommon(DependencyProperty dp, Object value, PropertyMetadata metadata, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType, Boolean isInternal)
   在 System.Windows.DependencyObject.SetValue(DependencyProperty dp, Object value)
   在 System.Windows.Controls.PopupControlService.RaiseToolTipOpeningEvent()
   在 System.Windows.Controls.PopupControlService.InspectElementForToolTip(DependencyObject o)
   在 System.Windows.Controls.PopupControlService.OnMouseMove(IInputElement directlyOver, Point pt)
   在 System.Windows.Controls.PopupControlService.OnPostProcessInput(Object sender, ProcessInputEventArgs e)
   在 System.Windows.Input.InputManager.RaiseProcessInputEventHandlers(ProcessInputEventHandler postProcessInput, ProcessInputEventArgs processInputEventArgs)
   在 System.Windows.Input.InputManager.ProcessStagingArea()
   在 System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
   在 System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
   在 System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
   在 System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   在 System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   在 MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   在 MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
   在 System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   在 System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
   在 System.Windows.Threading.Dispatcher.LegacyInvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs)
   在 MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
   在 MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)
   在 System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)
   在 System.Windows.Threading.Dispatcher.PushFrame(DispatcherFrame frame)
   在 System.Windows.Application.RunDispatcher(Object ignore)
   在 System.Windows.Application.RunInternal(Window window)
   在 System.Windows.Application.Run(Window window)
   在 EpointZaoJia_WPF.App.Main(String[] args)

4 个回复

倒序浏览
KNight
中级会员   /  发表于:2016-7-19 14:58:37
沙发
有Demo可以还原问题吗?
回复 使用道具 举报
Alice
社区贡献组   /  发表于:2016-7-19 17:37:33
板凳
谢谢您的反馈。
从异常信息来看,是在改变可视区域的Size的时候发生了异常。
仅从描述信息,我们无法重现该问题,我们需要能重现该问题Demo,然后才能帮您看看。
请点击评分,对我的服务做出评价!  5分为非常满意!

葡萄城控件服务团队

官方网站: http://www.gcpowertools.com.cn
回复 使用道具 举报
gzgood
中级会员   /  发表于:2016-7-20 09:46:09
地板
因为是用户机子上出现的问题,本机也没有重现,所以暂时也没有demo
回复 使用道具 举报
Alice
社区贡献组   /  发表于:2016-7-20 12:21:49
5#
gzgood 发表于 2016-7-20 09:46
因为是用户机子上出现的问题,本机也没有重现,所以暂时也没有demo

之前有类似的异常,是因为设置了Border的Enable属性。
请参考帖子,检查是否有类似的设置:http://gcdn.gcpowertools.com.cn/showtopic-19695-1-1.html

如果不是此类问题,我们需要您提供一个可以重现问题的Demo,才可以确定是什么问题。
请点击评分,对我的服务做出评价!  5分为非常满意!

葡萄城控件服务团队

官方网站: http://www.gcpowertools.com.cn
回复 使用道具 举报
您需要登录后才可以回帖 登录 | 立即注册
返回顶部