visual-studio-2008 - 值未落在预期范围内

标签 visual-studio-2008 forms c#-3.0 compact-framework windows-mobile-6.1

尝试显示表单设计器时出错。

查看错误图片:

enter image description here

屏幕代码:

public partial class frmCanalVenda : frmEdit
{
    public frmCanalVenda(CanalVenda canal, Cliente cli)
        : base(canal)
    {
        InitializeComponent();
        bdsCliente.DataSource = cli;
        eabBar.ReadOnlyView = false;
    }

    private void frmCanalVenda_Load(object sender, EventArgs e)
    {
        try
        {
            Cursor.Current = Cursors.WaitCursor;

            bdsAgrupamento.DataSource = Agrupamento.GetAll(DatabaseAFV.Connection);
            bdsCanal.DataSource = Canal.GetAll(DatabaseAFV.Connection);
            bdsSubCanal.DataSource = SubCanal.GetAll(DatabaseAFV.Connection);
            bdsEspecializacao.DataSource = Especializacao.GetAll(DatabaseAFV.Connection);
            bdsOperacao.DataSource = Operacao.GetAll(DatabaseAFV.Connection);
            bdsPorte.DataSource = Porte.GetAll(DatabaseAFV.Connection);
        }
        finally
        {
            Cursor.Current = Cursors.Default;
        }
    }
}

图像文本

To prevent possible data loss before loading the designer, the following errors must be resolved:

Value does not fall within the expected range.

Instances of this error (1)

  1. Hide Call Stack at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo) at Microsoft.VisualStudio.NativeMethods.ThrowOnFailure(Int32 hr, Int32[] expectedHRFailure) at Microsoft.VisualStudio.Shell.Design.Serialization.DesignerDocDataService.GetFileDocData(String fileName, FileAccess access, String createTemplate, Boolean addToHostList, Boolean nestedItem) at Microsoft.VisualStudio.Shell.Design.Serialization.DesignerDocDataService.GetChildDocData(String name, FileAccess access, String createTemplate) at Microsoft.VisualStudio.Design.Serialization.CodeDom.VSCodeDomDesignerLoader.GetResourceDocData(CultureInfo info, FileAccess access) at Microsoft.VisualStudio.Design.Serialization.CodeDom.VSCodeDomDesignerLoader.System.ComponentModel.Design.IResourceService.GetResourceReader(CultureInfo info) at System.ComponentModel.Design.Serialization.ResourceCodeDomSerializer.SerializationResourceManager.GetMetadata() at System.ComponentModel.Design.Serialization.ResourceCodeDomSerializer.SerializationResourceManager.GetMetadataEnumerator() at System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializePropertiesFromResources(IDesignerSerializationManager manager, Object value, Attribute[] filter) at System.ComponentModel.Design.Serialization.TypeCodeDomSerializer.Deserialize(IDesignerSerializationManager manager, CodeTypeDeclaration declaration) at System.ComponentModel.Design.Serialization.CodeDomDesignerLoader.PerformLoad(IDesignerSerializationManager manager) at Microsoft.VisualStudio.Design.Serialization.CodeDom.VSCodeDomDesignerLoader.PerformLoad(IDesignerSerializationManager serializationManager) at System.ComponentModel.Design.Serialization.BasicDesignerLoader.BeginLoad(IDesignerLoaderHost host)

最佳答案

万岁玛丽:重新启动 Visual Studio 对我有用。

关于visual-studio-2008 - 值未落在预期范围内,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5735269/

相关文章:

c++ - 在 Visual Studio 2008 下出现 long long int 编译器错误的原因是什么?

javascript - 如何测试 URL 是否为有效图像(在 javascript 中)?

java - JSP 中的隐藏输入在将其传递给 servlet 时会产生 null

c# - 如何以编程方式使用 SVN 和 .NET 进行文件版本控制?

visual-studio-2008 - Silverlight 开发 [Visual Studio 2008 与 Expression Blend]

visual-studio-2008 - 即使不导入命名空间,项目也会被导入

c# - 删除和退格在 ReSharper 中不起作用

javascript - Angular 的 FormArray 什么时候是传统数组,什么时候是 FormArray 对象?

c# - quartz 调度器 : How to pass custom objects as JobParameter?

c#-3.0 - 扩展方法及其在软件工程中的影响(或者它真的是一个好主意吗?)