krishna chava

Forum Replies Created

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • in reply to: Need Webservice..url..for FAX FINDER #3022
    krishna chava
    Participant

    Thank you Jesse, It worked for me.

    1 more question, can you let me know how to reduce the resolution?

    Right now i am getting the fax with very good resolution. Thanks for the immediate responses.

    in reply to: Need Webservice..url..for FAX FINDER #3020
    krishna chava
    Participant

    I fixed the issue. Thanks for your help,

    Its the issue in xml file

    Instead of <organization> i have created my xml with <Organization>.

    I never expected a small difference in the case will error.

    Hope this will help other users.

    Right now i am able to send plain text with the help of your sample.

    Can any one provide me any sample to fax a pdf that i have on my server machine. I will be gr8 ful if i get sample of xml for this one. i tried changing xml tags as below… bug giving error 400.

    <attachment>

    <location>C:Krishnaxml files</location>

    <name>mypdffile.pdf</name>

    <content_type>application/pdf</content_type>

    in reply to: Need Webservice..url..for FAX FINDER #3017
    krishna chava
    Participant

    I am trying to implement the functionality in a webapplication using vb.net. But i am getting the below error:

    The RemoteServer returned an error:(400) Bad Request.

    I used the same xml file and below is my code: Can any one of you please help me in this issue…

    Dim url As String = “http://10.0.0.250/ffws/v1/ofax&#8221;

    ‘Dim request As HttpWebRequest = DirectCast(Net.WebRequest.Create(url), HttpWebRequest)

    Dim request As HttpWebRequest

    request = HttpWebRequest.Create(“http://10.0.0.280/ffws/v1/ofax&#8221;)

    request.Credentials = New NetworkCredential(“userid”, “xyz”)

    request.Method = “POST”

    request.ContentType = “text/xml”

    Dim fileSize As New FileInfo(“C:Userskrishnadocumentsvisual studio 2010ProjectsWebApplication5WebApplication5schedule.xml”)

    Dim len As Integer = CInt(fileSize.Length)

    Dim textIn As New StreamReader(New FileStream(“C:Userskrishnadocumentsvisual studio 2010ProjectsWebApplication5WebApplication5schedule.xml”, FileMode.Open, FileAccess.Read))

    Dim TextLines As String = textIn.ReadToEnd()

    Dim byteArray As Byte() = Encoding.UTF8.GetBytes(TextLines)

    ‘request.ContentLength = len

    request.ContentLength = byteArray.Length

    Dim dataStream As Stream = request.GetRequestStream()

    dataStream.Write(byteArray, 0, byteArray.Length)

    textIn.Close()

    dataStream.Close()

    Dim response As HttpWebResponse = request.GetResponse()

    ‘Console.WriteLine(DirectCast(response, HttpWebResponse).StatusDescription)

    ‘ Label1.Text = (DirectCast(response, HttpWebResponse).StatusDescription)

    Dim data As Stream = response.GetResponseStream()

    Dim reader As New StreamReader(data)

    Dim responseFromServer As String = reader.ReadToEnd()

    ‘Label2.Text = responseFromServer

    reader.Close()

    data.Close()

    response.Close()

    I will be gr8full if i get a solution for this.

    Thank you,

    Krishna.

    in reply to: Need Webservice..url..for FAX FINDER #3016
    krishna chava
    Participant

    Thank your very much for the code.

Viewing 4 posts - 1 through 4 (of 4 total)