Talk:REST/@comment-203.176.130.117-20130123045032

From Request Tracker Wiki
Revision as of 15:52, 6 April 2016 by Admin (talk | contribs) (1 revision imported)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search


--      Dot net comment

      Dim ticketNumber As String = "8338"

      Dim userName As String = "sdsd"

      Dim password As String = "asdsadasdad"

      Dim URL As String = "http://yourdomain/rt/REST/1.0/ticket/" + ticketNumber + "/comment?user=" + userName + "&pass=" + password

      Dim Client As New System.Net.WebClient

      Dim postString As String

      postString = "content=Text: RT Test2  dd 1" + vbLf + "Action: Comment"

      Dim postBytes As Byte() = System.Text.Encoding.ASCII.GetBytes(postString)

      Dim responseArray As Byte() = Client.UploadData(URL, "POST", postBytes)

      TextBox1.Text = System.Text.Encoding.ASCII.GetString(responseArray)