我正在尝试登录到 SharePoint 2010 ULS 日志,但没有取得多大成功。我添加了对http://localhost/_vti_bin/Diagnostics.asmx
我的 Silverlight 项目的引用,我正在安装 sharepoint 的同一台机器上工作,然后我使用以下代码
private void button1_Click2(object sender, RoutedEventArgs e)
{
SharePointDiag.SharePointDiagnosticsSoapClient client = new SharePointDiag.SharePointDiagnosticsSoapClient();
client.SendClientScriptErrorReportCompleted += new EventHandler<SharePointDiag.SendClientScriptErrorReportCompletedEventArgs>(sendComp);
client.SendClientScriptErrorReportAsync("TEST", "TEST", 123, "TEST", "<client><browser name='Internet Explorer' version='9.0'></browser><language> en-us </language></client>"
, "<stack><function depth='0' signature=' myFunction() '>function myFunction() { 'displaypage ();}</function></stack>", "TEST");
}
代码没有给出错误或结果,只是完成的事件参数为空。在 Fiddler 中,看起来调用工作正常,但是当我检查“C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\LOGS”中的日志时,我的消息不在其中。
任何想法或提示都会很棒。谢谢