echo ""; echo ""; echo ""; echo ""; if(!is_admin){echo "";} » .NET 仲子说

欢迎您光临我的个人网站!


2011-11-20

往IIS 7.5的Application Pools中添加ASP .NET v4.0

Posted in .NET at 21:23 by 仲远

标签:
Zhongyuan Wang

97100fe403b8

??????/WCF Service???ASP .NET 4.0?????????IIS?Application Pools???ASP .NET v4.0??????????????????????????
HTTP Error 404.3 – Not Found
The page you are requesting cannot be served because of the extension configuration. If the page is a script, add a handler. If the file should be downloaded, add a MIME map. Detailed Error InformationModule StaticFileModule.
????????????????????????????IIS???ASP .NET v4.0?Application Pool????????????????
1. ??“?? -> ???? -> ...查看全文

2011-08-01

在Windows Azure中读取配置文件中的连接设置

Posted in .NET at 11:40 by 仲远

标签:

???Windows Azure???????????????????????Azure??????????????????????Azure???????
var storageAccount = CloudStorageAccount.FromConfigurationSetting(”DataConnectionString”);
???????????Azure??????????????????????SetConfigurationSettingPublisher??????????????????
Unhandled Exception: System.InvalidOperationException: ConfigurationSettingSubscriber needs to be set before FromConfigurationSetting can be used
at Microsoft.WindowsAzure.CloudStorageAccount.FromConfi...查看全文

2011-07-13

C#中简单的多线程调用

Posted in .NET at 10:41 by 仲远

标签:

????????????????????????????????????????????????????????.NET Framewrok 4?????Parallel.For?Parallel.Foreach???????????????????????????????????
List<string> lines = GetLines(); //get the set of elements
Parallel.ForEach<string>(lines, line =>
{
string[] fields = line.Split(new char[] { ‘\t’ });
//Do something with the element: line
});
???????lines????????????list??????collection?Parallel.ForEach<string>????????string??...查看全文

2011-05-17

一种让WCF服务实例长期存在的方法

Posted in .NET at 15:14 by 仲远

标签:
一种让WCF服务实例长期存在的方法

??????????????????WCF??????????????????????????API???????.NET??????WCF????????????????????1?WCF??????Client????????WCF????????????????????????????????????2?????IIS???WCF???????????IIS?????????????????????????????WCF????????????????????Client?????WCF??????
????????IIS?????????WCF????????????????????
?1??service??????????InstanceContextMode = InstanceContextMode.Single??????
[ServiceBehavior(InstanceContextMode = InstanceContextMode.Single)]
public class Service1 : ISer...查看全文

2011-04-22

WCF Service无法取同名方法

Posted in .NET at 13:06 by 仲远

标签:

?WCF?????????????????????“Cannot have two operations in the same contract with the same name”??????????OperationContract??????“??”?(Name = “XXXXXXXXXXX”)???????????????????Client??????????????????????
??????
In our introductory WCF tutorial, I created a basic service contract that accepted a string and returned a reversed version of it. For this tutorial, I want to overload this function to also accept a character array. If I were […]

...查看全文

2011-02-25

IIS7中的unable to generate a temporary class错误解决办法

Posted in .NET at 11:55 by 仲远

标签:

???IIS7??????????Service Unavailable?????????????????????????Just-In-Time Debugger?go into?????????
?????
System.ServiceModel.CommunicationException was unhandled
  Message=There was an error in serializing body of message SearchRequest1: ‘Unable to generate a temporary class (result=1).
error CS2001: Source file ‘C:\Windows\TEMP\s0phakvt.0.cs’ could not be found
error CS2008: No inputs specified
‘.  Please see InnerException for ...查看全文

2011-02-22

添加WCF Service作为Service Reference时遇到错误的解决办法

Posted in .NET at 11:42 by 仲远

标签:

??WCF Service????????????????Self-Hosting??????????????????????????Hosting.exe????IIS??????????IIS???????IIS?????W3wp.exe???????IIS????????Web Service?????Publish????????Application/Virtual Website.
??????
?Windows Server 2008 SP2 + IIS7???????IIS???WCF Service???????????Service??????????Client???????Service Reference????????http://myserver/myservice/Service.svc?????????????????“There was an error downloading ‘http://myserver/myservice/Service.svc?xsd=xsd0’”?
?????<...查看全文

2010-10-22

代码是如何炼成的

Posted in .NET at 17:14 by 仲远

标签:

???????????????????????????????????????????????????????????????????????????
??????????????
????????listA?listB????????????? listA{pa1=“w1 w2 w3”, pa2=”w2 w1 w4″, pa3=”w5, w7, w6″, … } ,  listB{pb1=“w11 w12 w31”, pb2=”w21 w11 w41″, pb3=”w13, w21, w16″, … } ?listA?listB???????????????????????????????liatA?pa1, pa2, pa3…?listB??pb1, pb2, pb3… ???????????????????????????????????????pa1 pb1 8762??pa1 pb2 ...查看全文

2010-10-22

ASP.NET网站内配置代理

Posted in .NET at 14:33 by 仲远

标签:

???ASP.NET????????????????????feeds????????????Debug????????Release??????????????????????????????????????????????????????????????????????????????ASP.NET???????????????
??????
(1)??????
WebProxy proxyObject = new WebProxy(“http://proxyserver:80/”,true);
WebRequest req = WebRequest.Create(“http://www.example.com”);
req.Proxy = proxyObject;
(2)?Web.config????????
<configuration>
  <system.net>
    <...查看全文

2010-08-10

WCF服务运行一段时间后客户端无法连接WCF服务的解决办法

Posted in .NET at 22:11 by 仲远

标签:

Windows Communication Foundation (WCF)?Microsoft????????????????????????.NET Framework 3.5???????????????????????????????????????????????????
?????WCF????Web????????????????????????API?????????????????????API??????WCF?????????????????????????????
???WCF???????????????WCF???????Client??????????WCF?????????????????????WCF Client????Web????????WCF???????Timeout??????WCF????????WCF???????
?????????????????????????????“We were creating instances of the Service Reference proxie...查看全文