自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(40)
  • 收藏
  • 关注

转载 wpf 查找控件

public List<T> GetChildObjects<T>(DependencyObject obj, Type typename) where T : FrameworkElement { DependencyObject child = null; List<T> c...

2019-09-03 15:07:00 536

转载 xcode Could not launch "" ; has denied the launch request

xcode Could not launch "" ; “”“ has denied the launch request(注意,这种方式不能调试)1、编辑scheme2、Build Configuration是Debug;Debug executable取消选中转载于:https://www.cnblogs.com/akiing/p/10529015....

2019-03-14 11:14:00 232

转载 xcode Automatic signing is unable to resolve an issue with the "ShowCar-IOS" target's entitlements

1、https://stackoverflow.com/questions/37806538/code-signing-is-required-for-product-type-application-in-sdk-ios-10-0-stic2、钥匙串访问,删除证书,修改登录限制转载于:https://www.cnblogs.com/akiing/p/10528870.html...

2019-03-14 11:02:00 857

转载 wpf datagridtemplatecolumn visibility binding

因为datagridtemplatecolumn不在Virsual Tree中,不能继承DataGrid的DataContext,所以想要绑定到datagridtemplatecolumn的 visibility ,需要添加一个代理1、在Resources添加FrameworkElement,DataContext绑定为当前DataContext<UserCo...

2019-01-28 16:57:00 672

转载 wpf Listbox 设置ItemContainerStyle后,ItemTemplateSelector不能触发

解决方案:将Listbox 的ItemTemplateSelector 改为ItemContainerStyle中ContentPresenterContentTemplateSelector 属性转载于:https://www.cnblogs.com/akiing/p/10239574.html

2019-01-08 16:12:00 998

转载 swift+moya URLCahe

1、定义获取缓存策略的接口import Foundationprotocol CachePolicyGettable {  var cachePolicy: URLRequest.CachePolicy {get}}2、TargetType 实现该接口extension MoyaAPI: TargetType, CachePolicyGettable ...

2018-09-29 15:18:00 205

转载 wpf Textbox 点击选中全部文本

用法:依赖属性SelectTextOnFocus.Active = Truepublic class SelectTextOnFocus : DependencyObject { public static readonly DependencyProperty ActiveProperty = DependencyProperty.Registe...

2018-09-28 10:37:00 1224

转载 vmware mac 分辨率设置

1.安装vmware tool2.关闭虚拟机,在设置中找到显示器项3.选中“加速3D图形”4.在监视器中,选中 指定监视器设置,使用任意分辨率5.如果没有可用分辨率,手动输入,例如 1680*1050转载于:https://www.cnblogs.com/akiing/p/9675874.html...

2018-09-19 17:47:00 501

转载 wpf Command canExecute 更新

可以调用以下语句通知CommandManager.InvalidateRequerySuggested();转载于:https://www.cnblogs.com/akiing/p/9366450.html

2018-07-25 16:03:00 609

转载 Binding Enum to ComboBox

1、添加MarkupExtensionpublic class EnumToSourceExtension : MarkupExtension { private Type _type; public EnumToSourceExtension(Type type) { ...

2018-04-04 10:48:00 97

转载 WPF Prefix 'attach' does not map to a namespace.

这个是用附加属性时,一定要在属性前面加Path=Visibility="{Binding Path=PlacementTarget.(attach:CommonAttachedProperties.IsEditable),RelativeSource={RelativeSource Mode=Self}}"转载于:https://www.cnblogs.com/ak...

2018-03-19 16:09:00 72

转载 C# 用ManulResetEvent 控制Thread的 Suspend、Resume

class Program { static void Main(string[] args) { Thread thread = new Thread(Work); thread.Start(); Console.ReadLine(); ...

2018-01-30 10:12:00 142

转载 C# 监控Windows睡眠与恢复

SystemEvents.PowerModeChanged += SystemEvents_PowerModeChanged;private void SystemEvents_PowerModeChanged(object sender, PowerModeChangedEventArgs e) { switch (e.Mode)...

2017-10-30 17:18:00 951

转载 c# DataTable to Object Mapping

public static class DataTableExtensions{ public static IList<T> ToList<T>(this DataTable table) where T : new() { IList<PropertyInfo> properties = typeof(T).G...

2017-09-28 17:35:00 271

转载 C# DispatcherTimer Start之后立即执行

如果DispatherTimer 的Interval 不是在实例化时赋值,那么Start之后,Tick方法会立即执行一次。DispatcherTimer timer = new DispatcherTimer(){IsEnabled = true};timer.Tick += (sender, args) =>{Console.WriteLine("timer ...

2017-09-25 14:50:00 2762

转载 Visual studio 编译时copy文件、文件夹

项目属性--生成事件添加命令xcopy /y /d "$(SolutionDir)Dll\Linphone\*.dll" "$(TargetDir)\Linphone\"xcopy "$(ProjectDir)\Assets" "$(TargetDir)\Assets\" /S /Y转载于:https://www.cnblogs.com/akiing/p/7574004.ht...

2017-09-22 11:33:00 783

转载 c# 无法加载xxx.dll 找不到指定的模块(如何指定文件夹)

如果直接放在项目运行目录,例如bin/debug可以直接加载,但是这样比较乱。如果在放debug里面的一个文件夹里面,有可能会报错“无法加载xxx.dll 找不到指定的模块”。如果路径写成这样就会报错framework/linphone解决方法:将/ 改成"\"framework\linphone转载于:https://www.cnblogs.com/aki...

2017-09-20 10:38:00 420

转载 EntityFramework 找不到方法:“Void System.Data.Entity.DbModelBuilder.RegisterEntityType

问题原因,EF当前版本没有该方法,将EF版本升级即可。1、packages.config<package id="EntityFramework" version="6.1.3" targetFramework="net40" />2、app.config <configSections> <!-- For more infor...

2017-09-14 16:54:00 545

转载 wpf 全局异常捕获处理

/// <summary> /// App.xaml 的交互逻辑 /// </summary> public partial class App : Application { private const string Tag = nameof(App); public App() ...

2017-09-14 09:50:00 542

转载 wpf Shake

<Setter Property="RenderTransformOrigin" Value="0.5 0.5" /> <Setter Property="RenderTransform"> <Setter.Value> <RotateTra...

2017-09-11 17:10:00 51

转载 剪切具有CornerRadius的RectangleGeometry(可能在Ripple中用到)

剪切具有CornerRadius的RectangleGeometry(可能在Ripple中用到)1、新建Converterpublic class BorderClipConverter : IMultiValueConverter{ public object Convert(object[] values, Type targetType, object p...

2017-09-08 10:36:00 130

转载 C#调用DLL报“试图加载格式不正确的程序”

程序右键->属性->平台,改为(x86)转载于:https://www.cnblogs.com/akiing/p/7485564.html

2017-09-06 16:33:00 136

转载 Android This Activity already has an action bar supplied by the window decor

This Activity already has an action bar supplied by the window decor. Do not request Window.FEATURE_ACTION_BAR and set windowActionBar to false in your theme to use a Toolbar instead.解决方式:...

2016-04-28 21:45:00 96

转载 c# 获取文件夹下面所有文件夹列表

方法一: string dirPath = @"D:\App1"; List<string> dirs = new List<string>(Directory.GetDirectories(dirPath, "*", System.IO.SearchOption.AllDirectories)); ...

2014-10-29 17:15:00 508

转载 silverlight wpf Command提交时输入验证

silverlight 或WPF在MVVM模式中使用INotifyDataErrorInfo接口对输入进行验证时控件lostFocus时会触发验证,但在提交动作(例如button的Command)时,不触发验证。下面的方法提供控件输入验证统一触发。1、添加ValidationScope类public class ValidationScope { ...

2014-10-17 10:18:00 122

转载 WPF silverlight获取子控件(获取DataTemplate里的子控件)

public static class VisualTreeExtensions { /// <summary> /// 获取父节点控件 /// </summary> /// <typeparam name="T">子控件UI</typeparam> ...

2014-10-16 16:53:00 150

转载 silverlight wpf DataTemplate Command binding

<Grid x:Name="LayoutRoot" Background="White"> <CommonControl:NoapDataGrid MinHeight="120" Margin="10,0,10,10" HorizontalAlignment="Stretch" AutoGenerateColumns="False" ItemsSo...

2014-09-23 10:21:00 96

转载 c# 获取一年中的周/根据一年中的第几周获取该周的开始日期与结束日期

/// <summary> /// 获取一年中的周 /// </summary> /// <param name="dt">日期</param> /// <returns></returns> public static ...

2014-09-19 16:44:00 645

转载 MVVM 中 ViewModelBase和 CommandBase

1 public class ViewModelBase : INotifyPropertyChanged , IDisposable 2 { 3 public virtual string DisplayName { get; protected set; } 4 5 public event PropertyCh...

2013-11-26 22:51:00 704

转载 Sandcastle入门:创建C#帮助文档

Sandcastle入门:创建C#帮助文档  使用Sandcastle  4.1使用平台  (1)操作系统:  Windows Server 2003; Windows XP Service Pack 2; Windows Vista;  (2)必备软件:  Microsoft .NET Framework Version 2.0  HTML Help...

2010-06-22 11:19:00 138

转载 在VS中调用WebService正常,在IIS中没反应

原因:Silverlight调用WebSite类型的WebService的跨域问题解决方案:1、将ClientAccessPolicy.xml放到WebService所在的根目录这样对于WebApplication类型的WebService没有问题,但是对于WebSite类型的却不起作用原因是WebSite默认有一个虚拟路径,其根目录在该虚拟目录下,手工创建该虚拟目...

2010-04-11 10:34:00 190

转载 WCF跨域 这可能是由于试图以跨域方式访问服务而又没有正确的跨域策略,或策略不适用于 SOAP...

尝试向 URI“http://localhost:8001/AccountService.svc”发出请求时出错。这可能是由于试图以跨域方式访问服务而又没有正确的跨域策略,或策略不适用于 SOAP 服务。您可能需要与该服务的所有者联系,以发布跨域策略文件并确保该文件允许发送 SOAP 相关的 HTTP 标头。出现此错误也可能是由于使用的是 Web 服务代理中的内部类型而没有使用 Inte...

2009-11-17 13:13:00 124

转载 System.IO.DirectoryNotFoundException: 未能找到路径“xxx..App_Data\log.txt”的一部分。”...

解决方法:  在App_Data文件夹中新建一个log.txt文件转载于:https://www.cnblogs.com/akiing/archive/2009/11/16/1603759.html

2009-11-16 12:58:00 4663

转载 System.InvalidOperationException: 生成 XML 文档时出错 这样的错误 序列化类型 xxx 的对象时检测到循环引用...

关于在Webservice里使用LinqToSQL遇到一对多关系的父子表中子表需要ToList输出泛型而产生循环引用错误的解决办法! 做一个网站时,有2个表,是一对多的关系然后用生成器自动生成了一个LINQ To SQL类,然后查询子表时由于子表里也有个父表的属性,所以当把查询的结果ToList时又通过Webservice输出,产生了System.InvalidO...

2009-10-27 22:39:00 2104

转载 IIS WCF 发布

我用IIS 发布wcf出现了一点问题:用VS可以浏览到WCF服务的信息,而在IIS中就不能包括我前面写的(IIS 管理器无法验证此内置帐户是否有访问权 )(http://www.cnblogs.com/akiing/archive/2009/10/24/1589221.html)但是改了这个还是不行用wcftestclient运行后出现服务元数据可能无法访问。请确保服务正在运...

2009-10-24 17:55:00 47

转载 win7 vista IIS 管理器无法验证此内置帐户是否有访问权

服务器配置为将传递身份验证和内置帐户一起使用,以访问指定的物理路径。但是,IIS 管理器无法验证此内置帐户是否有访问权。请确保应用程序池标识具有该物理路径的读取访问权。如果此服务器加入到域中,并且应用程序池标识是 NetworkService 或 LocalSystem,则验证<domain>\<computer_name>$ 具有该物理路径的读取访问权,然后重新...

2009-10-24 17:10:00 133

转载 远程服务器返回了错误: NotFound。 WCF

silverlight 调用WCF的时候有时会出现“远程服务器返回了错误: NotFound。”的错误我上网查了下说可以用以下方法解决在WCF服务的类中加上[ServiceBehavior(IncludeExceptionDetailInFaults = true)] 然后在调用此服务的silverlight的初始化方法中加上boolregisterResul...

2009-10-23 22:09:00 190

转载 IE8 UL 兼容

在IE8用UL的时候会出现兼容问题例如UL的行间距会比一般大解决方法:将UL的css设置为{magin:0px;padding:0px}转载于:https://www.cnblogs.com/akiing/archive/2009/10/12/1581726.html...

2009-10-12 14:40:00 160

转载 博客背景图片设置

body{background:url("页面大背景图片地址") repeat scroll!important;}.logo{background:url("题图上背景图片地址") no repeat no scroll!mportant;}.banner{background:url("题图下背景图片地址") no repeat no scroll!mportant;}.menu{b...

2009-10-10 10:16:00 248

转载 “/”应用程序中的服务器错误 WebParts开发时出现的错误

“/”应用程序中的服务器错误。 在与 SQL Server 建立连接时出现与网络相关的或特定于实例的错误。未找到或无法访问服务器。请验证实例名称是否正确并且 SQL Server 已配置为允许远程连接。 (provider: SQL 网络接口, error: 26 - 定位指定的服务器/实例时出错) 解决方案:到C:\Windows\Microsoft.NET\F...

2009-10-09 22:10:00 132

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除