Click here to Skip to main content
15,922,407 members
Home / Discussions / C#
   

C#

 
GeneralRe: query Pin
Colin Angus Mackay19-Sep-08 4:52
Colin Angus Mackay19-Sep-08 4:52 
GeneralRe: query Pin
Ashfield19-Sep-08 8:54
Ashfield19-Sep-08 8:54 
GeneralRe: query Pin
J4amieC19-Sep-08 2:16
J4amieC19-Sep-08 2:16 
GeneralRe: query Pin
Harvey Saayman19-Sep-08 2:37
Harvey Saayman19-Sep-08 2:37 
GeneralRe: query Pin
J4amieC19-Sep-08 2:49
J4amieC19-Sep-08 2:49 
GeneralRe: query Pin
Harvey Saayman19-Sep-08 2:59
Harvey Saayman19-Sep-08 2:59 
GeneralRe: query Pin
J4amieC19-Sep-08 3:05
J4amieC19-Sep-08 3:05 
GeneralRe: query Pin
Harvey Saayman19-Sep-08 3:12
Harvey Saayman19-Sep-08 3:12 
GeneralRe: query Pin
J4amieC19-Sep-08 3:16
J4amieC19-Sep-08 3:16 
GeneralRe: query Pin
Harvey Saayman19-Sep-08 3:41
Harvey Saayman19-Sep-08 3:41 
QuestionHow to Run executable by a windows service Pin
Reddy Prakash18-Sep-08 20:50
Reddy Prakash18-Sep-08 20:50 
AnswerRe: How to Run executable by a windows service Pin
Giorgi Dalakishvili18-Sep-08 20:56
mentorGiorgi Dalakishvili18-Sep-08 20:56 
GeneralRe: How to Run executable by a windows service Pin
Reddy Prakash18-Sep-08 21:03
Reddy Prakash18-Sep-08 21:03 
GeneralRe: How to Run executable by a windows service Pin
Giorgi Dalakishvili18-Sep-08 21:05
mentorGiorgi Dalakishvili18-Sep-08 21:05 
GeneralRe: How to Run executable by a windows service Pin
#realJSOP18-Sep-08 23:47
professional#realJSOP18-Sep-08 23:47 
AnswerRe: How to Run executable by a windows service Pin
Vikram A Punathambekar18-Sep-08 22:53
Vikram A Punathambekar18-Sep-08 22:53 
GeneralRe: How to Run executable by a windows service Pin
Giorgi Dalakishvili18-Sep-08 22:59
mentorGiorgi Dalakishvili18-Sep-08 22:59 
GeneralRe: How to Run executable by a windows service Pin
Vikram A Punathambekar19-Sep-08 6:21
Vikram A Punathambekar19-Sep-08 6:21 
AnswerRe: How to Run executable by a windows service Pin
#realJSOP18-Sep-08 23:49
professional#realJSOP18-Sep-08 23:49 
QuestionSet timeout to asynchron calls Pin
greekius18-Sep-08 20:37
greekius18-Sep-08 20:37 
QuestionConnect to camera with C# Pin
Member 467828718-Sep-08 20:26
Member 467828718-Sep-08 20:26 
Hi,

I try deverlop source code which can coonect to Camera and get Image from
this camera. In code when I click button capture Image.It have error.


///////////This is My code//////////////////

string sourceURL = "http://192.168.1.4/snapshot.jpg?account=admin& password=12345678&res=0&qual=50";

byte[] buffer = new byte[100000];
int read, total = 0;
// create HTTP request

HttpWebRequest req = (HttpWebRequest) WebRequest.Create( sourceURL );
// get response

WebResponse resp = req.GetResponse( );
// get response stream

Stream stream = resp.GetResponseStream( );
// read data from stream

while ( ( read = stream.Read( buffer, total, 1000 ) ) != 0 )
{
total += read;
}
// get bitmap

Bitmap bmp = (Bitmap) Bitmap.FromStream(
new MemoryStream( buffer, 0, total ) );

////////////////End code

Problem is this line:
Bitmap bmp = (Bitmap) Bitmap.FromStream(
new MemoryStream( buffer, 0, total ) );
it have error message:"Invalid parameter used"

Please help me.
thanks

QuestionRe: Connect to camera with C# Pin
Mark Salsbery19-Sep-08 7:07
Mark Salsbery19-Sep-08 7:07 
QuestionBackgroundWorker method executing twice Pin
scody18-Sep-08 18:20
scody18-Sep-08 18:20 
AnswerRe: BackgroundWorker method executing twice Pin
N a v a n e e t h18-Sep-08 19:30
N a v a n e e t h18-Sep-08 19:30 
GeneralRe: BackgroundWorker method executing twice Pin
scody18-Sep-08 20:35
scody18-Sep-08 20:35 

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

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