Click here to Skip to main content
       

C#

 
GeneralRe: I need a help PinmemberBire50t17-Jan-13 19:18 
AnswerRe: I need a help PinmvpEddy Vluggen18-Jan-13 1:19 
GeneralRe: I need a help PinmemberBire50t17-Jan-13 19:21 
QuestionHi PinmemberBire50t16-Jan-13 21:19 
SuggestionRe: Hi PinmvpRichard MacCutchan16-Jan-13 23:38 
GeneralRe: Hi PinmemberBire50t17-Jan-13 19:26 
GeneralRe: Hi PinmvpRichard MacCutchan17-Jan-13 22:56 
Questionneed a help Pinmemberhelibell16-Jan-13 20:22 
Can anyone help me on this:
 
I was trying to access my IP camera and used the following code
 

string sourceURL = "ipaddress";
byte[] buffer = new byte[100000];
int read, total = 0;
HttpWebRequest req = (HttpWebRequest)WebRequest.Create(sourceURL);
req.Credentials = new NetworkCredential("username","password");
WebResponse resp = req.GetResponse();
Stream stream = resp.GetResponseStream();
while ((read = stream.Read(buffer, total, 1000)) != 0)
{
total += read;
}
Bitmap bmp = (Bitmap)Bitmap.FromStream(
new MemoryStream(buffer, 0, total));
 

but when i compiled the code, the following message will be displayed what can I do to solve this?
"Grab Error: System.Net.WebException:The remote server returned an error:(400)Bad request. at System.Net.HttpWebRequest.GetResponse()"
 
Thanks for your help.
AnswerRe: need a help Pinmember d@nish 16-Jan-13 20:26 
QuestionRe: need a help Pinmemberhelibell16-Jan-13 20:35 
AnswerRe: need a help Pinmember d@nish 16-Jan-13 20:47 
QuestionRe: need a help Pinmemberhelibell16-Jan-13 21:08 
AnswerRe: need a help PinmemberBire50t16-Jan-13 21:57 
QuestionC# use linq for on filename Pinmemberdcof16-Jan-13 19:24 
AnswerRe: C# use linq for on filename Pinmember d@nish 16-Jan-13 20:08 
GeneralRe: C# use linq for on filename Pinmemberdcof17-Jan-13 8:19 
AnswerRe: C# use linq for on filename PinmvpEddy Vluggen17-Jan-13 0:35 
GeneralRe: C# use linq for on filename Pinmemberdcof17-Jan-13 8:18 
QuestionRead every single keyboard press? [solved] [modified] PinmemberMidnight Ahri16-Jan-13 15:24 
GeneralRe: Read every single keyboard press? PinmemberPIEBALDconsult16-Jan-13 15:34 
QuestionRe: Read every single keyboard press? PinmemberMidnight Ahri16-Jan-13 15:52 
AnswerRe: Read every single keyboard press? PinmemberPIEBALDconsult16-Jan-13 15:56 
AnswerRe: Read every single keyboard press? [modified] PinmemberMidnight Ahri16-Jan-13 16:03 
GeneralRe: Read every single keyboard press? PinmemberPIEBALDconsult16-Jan-13 17:13 
GeneralRe: Read every single keyboard press? Pinmemberpt140116-Jan-13 19:30 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Advertise | Privacy | Mobile
Web02 | 2.8.140709.1 | Last Updated 12 Jul 2014
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid