February 17, 2014 at 5:16 am
To get the client ip followed the steps
1. Open the layout mode.
2. Click the menu “Report” -- > “Report Properties…”
3. Switch to “Reference” tab.
4. Click the top “Add” button, and then add the “System.Net”
5. After applying the follow steps, go to “Code” page, embed the following code:
Public Function GetClientIP() As String
Dim ipHost As System.Net.IPHostEntry
ipHost = System.Net.Dns.GetHostEntry(System.Net.Dns.GetHostName())
Return ipHost.AddressList(0).ToString()
End Function
6. Now, in the report, use the following expression to get the value:
=Code.GetClientIP()
Reference :
Error
Request for the permission of type 'System.Net.DnsPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed. (rsRuntimeErrorInExpression)
how to resolve the error.
DB : SQL server 2008
OS : Win 7 (32bit)
Thanks!
February 19, 2014 at 8:19 am
Had a quick look and does the following link shed any light on your problem as a potential solution?
February 21, 2014 at 4:44 am
Thanks for the Link but it does not give the solution rather it is trying to address the problem but not fully.
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply