Web 服务在从平板电脑调用时不写入日志



我们的应用程序正在调用一个Web服务。

通过浏览器调用此功能(使用Mozilla Firefox测试),此函数将正确写入日志文件(带有我们提供的值)。但是,当通过平板电脑调用此功能(在同一网络和其他网络上测试)时,日志中没有写任何内容。

很简单,看起来像这样:

<WebMethod()> _
Public Function CreateClient( _
    ByVal strUserID As String, _
    ByVal strVehicleID As String, _
    ByVal strUnit As String, _
    ByVal strHouse As String, _
    ByVal strStreet As String, _
    ByVal strCity As String, _
    ByVal strContactName As String, _
    ByVal strPhone As String, _
    ByVal strComments As String)
    Dim strReturn As String = "14"
    Dim strLog As String = ""
    strLog = "CreateClient strUserID = " & strUserID & ", strVehicleID = " & strVehicleID & ", strUnit = " & strUnit & ", strHouse = " & strHouse & ", strStreet = " & strStreet & ", strCity = " & strCity
    strLog &= ", strContactName=" & strContactName & ", strPhone=" & strPhone & ", strComments=" & strComments
    Class1.WriteLogEntry(strLog, Class1.LOG_TYPE_DEBUG)
    Return strReturn
End Function

我们知道我们正在联系并调用正确的Web服务&amp;功能是因为当我们更改返回值时,平板电脑在每次部署后显示正确的值。例如:当返回值设置为" 1"时,平板电脑会恢复" 1",然后将其更改为" 14"后,平板电脑还会恢复" 14"。

有人知道为什么未编写日志和/或如何修复该日志?

注意:如果您需要查看我们如何称呼它的Android代码,我会发布它,但是再次,我认为这是不必要的,因为我们已经知道我们已经正确地称呼它并获得正确的返回值。

不确定问题是什么,但是在更改了两件事之后,日志开始再次工作:

  • 将所有代码从Class1移至模块(Module

  • 更改了要保存的目标文件。

是否有可能在文件上锁定其他东西,从而阻止该日志被编写?也许类和模块没有相同的文件编写权限?

最新更新