RSS图片
C#开发
Model Binding Model Binding in Razor Pages is the process that takes values from HTTP requests and maps them to handler method parameters or PageModel properties. Model binding reduces the need for the developer to manually extract values from the request and then assign them, one by one, to variables or properties for later processing. This work is repetitive, tedious and......
作者:发表于:2020/06/01 点击:0 评论:0
表示该变量为null时,不执行该语句。 当val=null时 val?.ToLower();返回值=null 没有“?”时,显然要报错的。 ...
作者:发表于:2020/02/02 点击:12 评论:0
今日在IIS7.5上加了一个FTP站点,创建完ftp用户后,用这个用户在远程登录发现  出现 "530 Valid Hostname is expected" 解决办法: 1.若是你的ftp绑定的域名是ftp.abc.com,用户名为user 则登录时需要用 ftp.abc.com|user; 注意中间用"|"分隔 2.把绑定删除,直接用用户名登录也可以 ———————————————— 版权声明:本文为CSDN博主「ChenZhuYu」的原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接及本声明。 原文链接:https://blog....
作者:发表于:2019/12/27 点击:15 评论:0
https://www.paragon-inc.com/blog/easy_excel_interaction_pt5 http://gruffcode.com/2013/10/30/simple-excel-export-with-epplus/ https://stackoverflow.com/questions/13396604/excel-to-datatable-using-epplus-excel-locked-for-editing http://www.jb51.net/article/80065.htm https://code.msdn.microsoft.com/CSASPNETCascadingDropDownLi-0a3f1ecf...
作者:发表于:2018/04/09 点击:98 评论:0
Follow these simple steps: Right Click on "devenv.exe" Click "Troubleshoot compatibility" Click "Troubleshoot program" Check "The program requires additional permissions" Click "Next" Click "Test the program...". It should launch Visual Studio as Administrator Click "Next" Click "Yes, save these settings for this program" Click "Close the troubleshooter" Now the Visu......
作者:发表于:2018/03/23 点击:40 评论:0
Tool:Visual Studio 2013 Ultimate OS:Windows Server 2012 .NET Framework : 4.5.1   這是自ASP.NET4.5版就新增的新功能,在ASP.NET Web Forms網站之中,可以利用ScriptManager來管理JavaScript,例如jQuery,讓引用更方便。 建立一個Web Site 使用NuGet下載jQuery,目前版本2.0.3 加入Global Application Class Add Code: void Application_Start ( ob......
作者:发表于:2018/03/18 点击:78 评论:0
using System; using System.Collections.Generic; using System.Text; using System.Reflection; using System.IO; namespace MB.Utility.Log {     /// <summary>     ///      /// </summary>     public class SingleLog     {         StreamWriter sw = null;         // string LogFile; ......
作者:发表于:2018/03/17 点击:34 评论:0
I faced lot of trouble when i do difference between  two versions in VSS, it is not specifying what exactly the change is. So i thought of exploring how to use one of the best open source diff tool to make this. In this post i am going to explain how can we integrate WinMerge’s diff tool with VSS 5.0. Pre-Requisites: 1. VSS 5.0 installed 2. Winmerge 2.12.4 installed. Steps: 1......
作者:发表于:2018/03/17 点击:38 评论:0
How to Clear INetCache in C# Step 01. Create Variable private const int INTERNET_OPTION_END_BROWSER_SESSION = 42; [DllImport("wininet.dll", SetLastError = true)] private static extern bool InternetSetOption(IntPtr hInternet, int dwOption, IntPtr lpBuffer, int lpdwBufferLength); Step 02. Create Method private static void ClearIEFolder() {     try     {    ......
作者:发表于:2018/03/17 点击:43 评论:0
内插字符串以美元符号$开头,后面跟一个""包含的字符串,字符串中大括号包含的内容会由编译器计算成一个字符串,如果是对象的话就会调用对象的ToString方法,然后拼接产生结果。 如果要在内插字符串中包含大括号,就需要连续两个大括号{{ }}这样的。单大括号里的内容不仅仅可以是一个值,表达式也可以 string name = "microsoft"; int age = 23; Console.WriteLine("{0} is {1} years old.", name, age); //使用内插字符串 Console.WriteLine($...
作者:发表于:2018/02/19 点击:259 评论:0