显示可视化器错误“无法加载此自定义查看器” [英] Show Visualizers Error "could not load this custom viewer"

查看:1411
本文介绍了显示可视化器错误“无法加载此自定义查看器”的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我尝试通过标准DataSet可视化程序检查DataSet时,我看到这个错误无法加载这个自定义查看器
我写了简单的数据集可视化,但是错误也抛出了。

When I try to inspect DataSet by standard DataSet visualizer I see this error "could not load this custom viewer". I wrote simple dataset visualizer, but error throws anyway too.

在具有相同配置可视化的其他计算机上显示没有任何错误。

On other computers with the same configuration visualizer show without any errors.

操作系统: Windows 7 x86(发布)

VS: Visual Studio 2010 RC

VS: Visual Studio 2010 RC

有任何想法吗?

我重新安装VS没有任何效果。

I reinstall VS with no effect.

推荐答案

我发现解决方法!
我更改了DevExpress模块​​的源代码并重新编译它。之后,我撤消参数到NetFx40_LegacySecurityPolicy enabled =false,并享受。 :)

I found workaround! I changed source code of DevExpress module and recompile it. After that I undo parameter to NetFx40_LegacySecurityPolicy enabled="false", and enjoy. :)

文件是%DeveloperExpress.NET%\Sources\DevExpress.Data\Utils\Security.cs

File is "%DeveloperExpress.NET%\Sources\DevExpress.Data\Utils\Security.cs"

using System;
using System.Security;
using System.Security.Permissions;
namespace DevExpress.Data.Helpers {
    public static class SecurityHelper {
        public static bool IsPartialTrust {
            get {
                return !IsPermissionGranted(new ReflectionPermission(ReflectionPermissionFlag.MemberAccess));
            }
        }
        public static bool IsPermissionGranted(IPermission permission) {
            bool result = true;
/* (changed by Lion)
            try {
                PermissionSet ps = SecurityManager.ResolvePolicy((System.Security.Policy.Evidence)null);
                ps = ps.Copy();
                ps.AddPermission(permission);
                ps.Demand();
            }
            catch (SecurityException) {
                result = false;
            }
*/
            return result;
        }
    }
}

版本8.2的修补文件可从此处下载

Patched file for version 8.2 you can download from here

这篇关于显示可视化器错误“无法加载此自定义查看器”的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆