I'm新在这项工作,当我打开了一个项目,我得到这个错误,我可不是能找出what's回事。 有什么帮助吗?WPF设计视图错误
SO:WinXP Sp3,Visual Studio 2010 Express
在此先感谢。
Exception not controlled. Details: System.Reflection.TargetInvocationException Se produjo una excepción en el destino de la invocación. en System.RuntimeMethodHandle._InvokeMethodFast(IRuntimeMethodInfo method, Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeType typeOwner) en System.RuntimeMethodHandle.InvokeMethodFast(IRuntimeMethodInfo method, Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeType typeOwner) en System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks) en System.Delegate.DynamicInvokeImpl(Object[] args) en System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs) en MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(Object source, Delegate method, Object args, Int32 numArgs, Delegate catchHandler)
System.NullReferenceException Referencia a objeto no establecida como instancia de un objeto. en ControlPesajeLavanderia.ItemParte.NuevoItemParte_IsVisibleChanged(Object sender, DependencyPropertyChangedEventArgs e) en C:\Documents and Settings\golaizola\Mis documentos\Visual Studio 2010\Projects\ControlPesajeLavanderia\ControlPesajeLavanderia\usercontrols\ItemParte.xaml.vb:línea 186 en System.Windows.UIElement.RaiseDependencyPropertyChanged(EventPrivateKey key, DependencyPropertyChangedEventArgs args) en System.Windows.UIElement.OnIsVisibleChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) en System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs e) en System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e) en System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args) en System.Windows.UIElement.UpdateIsVisibleCache() en System.Windows.UIElement.InvalidateForceInheritPropertyOnChildren(Visual v, DependencyProperty property) en System.Windows.UIElement.OnIsVisibleChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) en System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs e) en System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e) en System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args) en System.Windows.UIElement.UpdateIsVisibleCache() en System.Windows.UIElement.InvalidateForceInheritPropertyOnChildren(Visual v, DependencyProperty property) en System.Windows.UIElement.OnIsVisibleChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) en System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs e) en System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e) en System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args) en System.Windows.UIElement.UpdateIsVisibleCache() en System.Windows.UIElement.InvalidateForceInheritPropertyOnChildren(Visual v, DependencyProperty property) en System.Windows.UIElement.OnIsVisibleChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) en System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs e) en System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e) en System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args) en System.Windows.UIElement.UpdateIsVisibleCache() en System.Windows.UIElement.SynchronizeForceInheritProperties(UIElement uiElement, ContentElement contentElement, UIElement3D uiElement3D, DependencyObject parent) en System.Windows.UIElement.OnVisualParentChanged(DependencyObject oldParent) en System.Windows.FrameworkElement.OnVisualParentChanged(DependencyObject oldParent) en System.Windows.Media.Visual.FireOnVisualParentChanged(DependencyObject oldParent) en System.Windows.Media.Visual.AddVisualChild(Visual child) en System.Windows.FrameworkElement.set_TemplateChild(UIElement value) en System.Windows.Controls.ContentPresenter.UseContentTemplate.BuildVisualTree(FrameworkElement container) en System.Windows.StyleHelper.ApplyTemplateContent(UncommonField
1 dataField, DependencyObject container, FrameworkElementFactory templateRoot, Int32 lastChildIndex, HybridDictionary childIndexFromChildID, FrameworkTemplate frameworkTemplate) en System.Windows.FrameworkTemplate.ApplyTemplateContent(UncommonField
1 templateDataField, FrameworkElement container) en System.Windows.FrameworkElement.ApplyTemplate() en System.Windows.FrameworkElement.MeasureCore(Size availableSize) en System.Windows.UIElement.Measure(Size availableSize) en System.Windows.Controls.Border.MeasureOverride(Size constraint) en System.Windows.FrameworkElement.MeasureCore(Size availableSize) en System.Windows.UIElement.Measure(Size availableSize) en System.Windows.Controls.Control.MeasureOverride(Size constraint) en System.Windows.FrameworkElement.MeasureCore(Size availableSize) en System.Windows.UIElement.Measure(Size availableSize) en System.Windows.Controls.Border.MeasureOverride(Size constraint) en System.Windows.FrameworkElement.MeasureCore(Size availableSize) en System.Windows.UIElement.Measure(Size availableSize) en MS.Internal.Designer.ZoomableViewPresenter.DesignerBackground.MeasureOverride(Size constraint) en System.Windows.FrameworkElement.MeasureCore(Size availableSize) en System.Windows.UIElement.Measure(Size availableSize) en System.Windows.Controls.Decorator.MeasureOverride(Size constraint) en Microsoft.Windows.Design.Interaction.DesignerView.MeasureOverride(Size constraint) en System.Windows.FrameworkElement.MeasureCore(Size availableSize) en System.Windows.UIElement.Measure(Size availableSize) en MS.Internal.Designer.Viewport.MeasureOverride(Size availableSize) en System.Windows.FrameworkElement.MeasureCore(Size availableSize) en System.Windows.UIElement.Measure(Size availableSize) en MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint) en System.Windows.Controls.ScrollContentPresenter.MeasureOverride(Size constraint) en System.Windows.FrameworkElement.MeasureCore(Size availableSize) en System.Windows.UIElement.Measure(Size availableSize) en System.Windows.Controls.Grid.MeasureCell(Int32 cell, Boolean forceInfinityV) en System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV) en System.Windows.Controls.Grid.MeasureOverride(Size constraint) en System.Windows.FrameworkElement.MeasureCore(Size availableSize) en System.Windows.UIElement.Measure(Size availableSize) en System.Windows.Controls.ScrollViewer.MeasureOverride(Size constraint) en System.Windows.FrameworkElement.MeasureCore(Size availableSize) en System.Windows.UIElement.Measure(Size availableSize) en System.Windows.Controls.Grid.MeasureOverride(Size constraint) en System.Windows.FrameworkElement.MeasureCore(Size availableSize) en System.Windows.UIElement.Measure(Size availableSize) en MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint) en System.Windows.Controls.ContentPresenter.MeasureOverride(Size constraint) en System.Windows.FrameworkElement.MeasureCore(Size availableSize) en System.Windows.UIElement.Measure(Size availableSize) en System.Windows.Controls.Control.MeasureOverride(Size constraint) en System.Windows.FrameworkElement.MeasureCore(Size availableSize) en System.Windows.UIElement.Measure(Size availableSize) en System.Windows.Interop.HwndSource.SetLayoutSize() en System.Windows.Interop.HwndSource.set_RootVisualInternal(Visual value) en System.Windows.Interop.HwndSource.set_RootVisual(Visual value) en MS.Internal.DeferredHwndSource.ProcessQueue(Object sender, EventArgs e)
UPDATE:
我创建了一个新的形式和复制所有XAML,直到我得到的错误。
和错误说:当我包含在这一行我自己的用户控件中出现错误。“对象引用不设置到对象的实例”
而且我不知道为什么...
请问您能帮我们翻译一下英文信息吗? – 2010-11-09 12:59:44
我认为它是'对象引用未设置为对象的实例'。 – mcm69 2010-11-09 13:06:44