在活动目录(Activity Directory)里找这个用户,然后设置合适的权限
解决方案 »
- MVC Linq to List<T>的问题和 view 强类型的问题
- 关于网页图片下载问题
- 关于绑定了GridView控件后怎么截取字符串!
- Command控件
- 使用window.Open方法打开了多个窗口,在使用window.close时如何只关闭指定的某个窗口?!
- 新闻系统(添加内容为何总是失败!)
- 请问 "将 varchar 值 '4,3,' 转换为数据类型为 int 的列时发生语法错误" 是数据库错了吗.怎么改?
- 把程序移到另一台机器,水晶报表运行出错
- 请问这个程序怎样分页?急??
- 请问在用C#写中使服务起组件获得焦点怎么写呢。如textbox
- 自定义控件调用的问题,大家帮忙看看
- 开发过大型商务网站的朋友请进! 也欢迎每位进来聊聊 !
如果没有,你可以添加Everyone相应的权限。
1:创建EventLogSourceInstaller解决方案,以及同名应用
2:在项目应用中创建AmmicEventLogInstaller.cs文件,内容附上
3:Build上述应用,在bin文件夹下得到EventLogSourceInstaller.dll创建得到上述的dll之后,就可以通过该dll自动创建ASPNET帐户
4:运行start\programs\vs.net\vs.net tools\vs.net command prompt,执行installUtil EventLogSourceInstaller.dll
5:在控制面板\管理工具\计算机管理\用户管理 下会看到ASPNET用户帐户具体可以参看
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnbda/html/emab-rm.asp
http://expert.csdn.net/Expert/topic/2260/2260855.xml?temp=1.427859E-02
AmmicEventLogInstaller.cs内容
-------------------------------------------
using System;
using System.Diagnostics;
using System.ComponentModel;
using System.Configuration.Install;namespace EventLogSourceInstaller
{
[RunInstaller(true)]
public class AmmicEventLogInstaller : Installer
{
private EventLogInstaller ammicEventLogInstaller; public AmmicEventLogInstaller()
{
//Create Instance of EventLogInstaller
ammicEventLogInstaller = new EventLogInstaller(); // Set the Source of Event Log, to be created.
ammicEventLogInstaller.Source = "ASPNET"; // Set the Log that source is created in
ammicEventLogInstaller.Log = "Application";
// Add ammicEventLogInstaller to the Installers Collection.
Installers.Add(ammicEventLogInstaller);
}
}
}