看板 C_Sharp 關於我們 聯絡資訊
小弟專題在用ip webcam 最近碰到了一個問題 在網頁上執行 http://url/cgi-bin/camctrl.cgi?move=right 可以讓我的ipcam變方向 就是可以往右的意思 想說在我的程式上加上一個button 讓我按一下就可以讓它往右 以下是我的程式碼 ------------------- // Creates an HttpWebRequest for the specified URL. HttpWebRequest myHttpWebRequest = (HttpWebRequest)WebRequest.Create("http://url/cgi-bin/camctrl.cgi?move=right"); // Sends the HttpWebRequest and waits for a response. HttpWebResponse myHttpWebResponse = (HttpWebResponse)myHttpWebRequest.GetResponse(); // Get the response. Stream streamResponse = myHttpWebResponse.GetResponseStream(); StreamReader streamRead = new StreamReader(streamResponse); string responseString = streamRead.ReadToEnd(); // Close the stream object. streamResponse.Close(); streamRead.Close(); // Releases the resources of the response. myHttpWebResponse.Close(); --------------------- 怎麼樣就是不會動阿~~~(吶喊) 想請問一下我寫的部分是那邊錯了? 謝謝板上的各位了 -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 163.17.132.161
mickfang:建立了Request,不用送什麼指令去觸發嗎? 08/30 04:58