|
Hi Eddy
I can't see the code u reply, could you do it again and make it clear please!
thanks
|
|
|
|
|
I didn't reply with any code.
You could try the AForge library with the MJPEGStream .
|
|
|
|
|
i only do it once man!
and i didn't see u helping, could u make it clear please?
thanks!
|
|
|
|
|
I am trying to display a video from my ip camera on a panel. I have used an "http request" to get the video from the camera and i got a problem with displaying the video on the panel, so i need a help please?
am using c#, on visual studio 2010, windows form application...
Thanks!
|
|
|
|
|
Bire50t wrote: i got a problem Well, please don't expect people to guess what it is.
Bire50t wrote: i need a help With what?
Please edit your question and put some useful detail into your question.
One of these days I'm going to think of a really clever signature.
|
|
|
|
|
Hi Richard...
here is my question..
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));
at last, i want to display the video on a panel on windows form application and i have no idea how? please help!
thanks! Smile |
|
|
|
|
|
Sorry, I don't know; try a Google search or some of the CodeProject articles[^].
One of these days I'm going to think of a really clever signature.
|
|
|
|
|
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.
|
|
|
|
|
sourceURL is not a valid URL. That's one of the possibilities.
"Bastards encourage idiots to use Oracle Forms, Web Forms, Access and a number of other dinky web publishing tolls.", Mycroft Holmes[ ^]
|
|
|
|
|
I would appreciate a little more detail please,
let's say my ip camera address is 192.168.10.15
so I used string sourceURL = "http://192.168.10.15/nphMotionJpeg?Resolution=320x240&Quality=Standard";
so where exactly might be the problem..
Thanks again.
|
|
|
|
|
Can you check if the URL and request parameters that you are providing are valid?
"Bastards encourage idiots to use Oracle Forms, Web Forms, Access and a number of other dinky web publishing tolls.", Mycroft Holmes[ ^]
|
|
|
|
|
Do you mean that the source address(URL),user name and password that I used is valid? If yes.
Then i can access my ip camera using the given address in my browser literally
Thanks again
|
|
|
|
|
Hi Tg?
use (string sourceURL = "http://192.168.10.15/en/AViewer.html?codec=jpeg";) instead of (string sourceURL = "http://192.168.10.15/nphMotionJpeg?Resolution=320x240&Quality=Standard";)
|
|
|
|
|
In a C# 2008 desktop application, I can using the following statement to select error reports that are displayed on excel spreadsheets:
string[] excelFiles = Directory.GetFiles(strFullpath, "*ErrorReport.xlsx")
.Select(path => Path.GetFileName(path))
.ToArray();
Due to the above, I have the following questions:
1. if I want to change the statement to select either "*bErrorReport.xlsx" or "*dErrorReport.xlsx" or "*ErrorReport.xlsx",
how would I change the statement I just displayed?
2. The above statement picks 3 excel spreadsheets and there are really only two excel spreadsheets. The excelspreadshets that are valid
include:
customer_number_bErrorReport.xlsx,
and customer_number_ErrorReport.xlsx.
The invalid value that is selected is
~customer_number_bErrorReport.xlsx.
Can you show me the code, so an invalid spreadsheet called ~customer_number_bErrorReport.xlsx is not selected?
|
|
|
|
|
In stead of Select , you can use Where and filter the file names there.
"Bastards encourage idiots to use Oracle Forms, Web Forms, Access and a number of other dinky web publishing tolls.", Mycroft Holmes[ ^]
|
|
|
|
|
Thanks! How do you mark that the question was answered?
|
|
|
|
|
dcof wrote: Can you show me the code, so an invalid spreadsheet called ~customer_number_bErrorReport.xlsx is not selected?
The LINQ is not required here; one can filter the required names by giving a filter-parameter to the GetFiles method[^].
public static string[] GetFiles(
string path,
string searchPattern,
SearchOption searchOption
)
|
|
|
|
|
|
It's like keylogger but I only want to know how many times they pressed the keyboard each day.
I'm doing it in windows form.
I'd love to have some help or at least what to type in google.
Edit :
Thank's to this[^] article.
modified 17-Jan-13 1:39am.
|
|
|
|
|
|
I'm going to join this keylogging into my chatting application so my friend chat less and work much more.
They'll be able to know how many letters they typed in a day.
Is that a bad idea?
I've searched everywhere in google and tried in new project but still can't.
You can see my history of question, I ask when I don't know what to do.
|
|
|
|
|
Then you aren't looking for what you said originally. Within your app you could do that, but then why would your friend use it? And mightn't he type in Notepad and then paste to your app?
Whatever you do, you won't get what you want anyway.
Just tell your friend to get back to work.
|
|
|
|
|
|
Midnight Ahri wrote: This is to make them enjoy working.
Doesn't sound like it.
|
|
|
|
|
> It's only for 3 of my friend.
> This is to make them enjoy working.
Smacks of "the floggings will continue until morale improves".
I think you may soon have 3 fewer friends if you go ahead with this.
You can't make people enjoy working, but it's easy to make them not enjoy working...
|
|
|
|