David Kadish
Forum Replies Created
-
AuthorPosts
-
David KadishParticipant
Hi Mike
Finally I figured it out.
In case somebody else needs it, here is the code (ASP.NET,VB)
———————-
Dim request As WebRequest
Dim responseData As String = “”
Dim str As String = “”Dim request As WebRequest = WebRequest.Create(“https://11.22.33.44/ffws/v1/users/USERNAME”)
request = WebRequest.Create(str)
request.Credentials = New NetworkCredential(NAME, PASSWORD)
request.Method = “GET”Try
Dim response As WebResponse = Request.GetResponse()
Dim strOK As String = CType(Response, HttpWebResponse).StatusDescription
If strOK = “OK” Then
responseData = WebResponseGet(request) ‘responseData
UserFaxNumber = FaxNumber(responseData)
response.Close()
End If
Catch ex As Exception
End TryDavid KadishParticipantHi Mike
The following is the code I am using.
————————————————-
Private Sub getUserInfo()
Dim response As WebResponseServicePointManager.Expect100Continue = False
Dim request As WebRequest = WebRequest.Create(“https://11.22.33.44/ffws/v1/ofax/”)
request.Credentials = New NetworkCredential(LoginUsername, LoginPassword)
request.Method = “POST”Dim postData As String = “GET https://11.22.33.44/ffws/v1/users/USERNAME HTTP/1.1”
Dim byteArray As Byte() = Encoding.UTF8.GetBytes(postData)request.ContentType = “application/xml”
request.ContentLength = byteArray.LengthDim dataStream As Stream = request.GetRequestStream()
‘ Write the data to the request stream.
dataStream.Write(byteArray, 0, byteArray.Length)
‘ Close the Stream object.
dataStream.Close()
‘ Get the response.
response = request.GetResponse()
Exit Sub
End Sub
———————————————————-
When I hold Ctrl key and click on https://11.22.33.44/ffws/v1/users/USERNAME I do get the right data, but no metter I try, I always get error on request.GetResponse() – “The remote server returned an error: (400) Bad Request.”
Thanks,David KadishParticipantHi
I checked in the manual and it seems like I need to use Retrieving User Information function. I don’t understand the example. Can you please tell me how I can use the function with my ASP.NET code?Thanks,
David KadishParticipantHi
Thank you for the reply.
We have FaxFinder® FF240 system.
I am an Intranet developer. In my intranet database I keep all the users, their phones and fax numbers. To get the fax numbers from FaxFinder, I login to Faxfinder app, click on Users and export the file to the folder. After that I read the file from the Internet and update the database. I have to do this every time there is new employee or somebody stops working here. I would like to automate the process and be able to read the data from the Intarnet directly. Is it possible?
Thanks, -
AuthorPosts