Click here to Skip to main content
11,706,979 members (48,897 online)
   

C#

 
GeneralRe: I need a help Pin
Bire50t17-Jan-13 19:18
memberBire50t17-Jan-13 19:18 
AnswerRe: I need a help Pin
Eddy Vluggen18-Jan-13 1:19
mvpEddy Vluggen18-Jan-13 1:19 
GeneralRe: I need a help Pin
Bire50t17-Jan-13 19:21
memberBire50t17-Jan-13 19:21 
QuestionHi Pin
Bire50t16-Jan-13 21:19
memberBire50t16-Jan-13 21:19 
SuggestionRe: Hi Pin
Richard MacCutchan16-Jan-13 23:38
mvpRichard MacCutchan16-Jan-13 23:38 
GeneralRe: Hi Pin
Bire50t17-Jan-13 19:26
memberBire50t17-Jan-13 19:26 
GeneralRe: Hi Pin
Richard MacCutchan17-Jan-13 22:56
mvpRichard MacCutchan17-Jan-13 22:56 
Questionneed a help Pin
helibell16-Jan-13 20:22
memberhelibell16-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 Pin
d@nish 16-Jan-13 20:26
member d@nish 16-Jan-13 20:26 
QuestionRe: need a help Pin
helibell16-Jan-13 20:35
memberhelibell16-Jan-13 20:35 
AnswerRe: need a help Pin
d@nish 16-Jan-13 20:47
member d@nish 16-Jan-13 20:47 
QuestionRe: need a help Pin
helibell16-Jan-13 21:08
memberhelibell16-Jan-13 21:08 
AnswerRe: need a help Pin
Bire50t16-Jan-13 21:57
memberBire50t16-Jan-13 21:57 
QuestionC# use linq for on filename Pin
dcof16-Jan-13 19:24
memberdcof16-Jan-13 19:24 
AnswerRe: C# use linq for on filename Pin
d@nish 16-Jan-13 20:08
member d@nish 16-Jan-13 20:08 
GeneralRe: C# use linq for on filename Pin
dcof17-Jan-13 8:19
memberdcof17-Jan-13 8:19 
AnswerRe: C# use linq for on filename Pin
Eddy Vluggen17-Jan-13 0:35
mvpEddy Vluggen17-Jan-13 0:35 
GeneralRe: C# use linq for on filename Pin
dcof17-Jan-13 8:18
memberdcof17-Jan-13 8:18 
QuestionRead every single keyboard press? [solved] Pin
Midnight Ahri16-Jan-13 15:24
memberMidnight Ahri16-Jan-13 15:24 
GeneralRe: Read every single keyboard press? Pin
PIEBALDconsult16-Jan-13 15:34
memberPIEBALDconsult16-Jan-13 15:34 
QuestionRe: Read every single keyboard press? Pin
Midnight Ahri16-Jan-13 15:52
memberMidnight Ahri16-Jan-13 15:52 
AnswerRe: Read every single keyboard press? Pin
PIEBALDconsult16-Jan-13 15:56
memberPIEBALDconsult16-Jan-13 15:56 
AnswerRe: Read every single keyboard press? Pin
Midnight Ahri16-Jan-13 16:03
memberMidnight Ahri16-Jan-13 16:03 
GeneralRe: Read every single keyboard press? Pin
PIEBALDconsult16-Jan-13 17:13
memberPIEBALDconsult16-Jan-13 17:13 
GeneralRe: Read every single keyboard press? Pin
pt140116-Jan-13 19:30
memberpt140116-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
Web04 | 2.8.150819.1 | Last Updated 30 Aug 2015
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid