|
i changed notifyfilter to just filename, and it seems to work now :S
|
|
|
|
|
I was thinking about how to store the names generated by the filewatcher
does the filewatcher store the filenames for me (that'd be really great!), but i'm guessing it doesn't
Just wondered how other people would go about storing this list. I might have 100 files in a folder that are created.
I was thinking about storing the file list as an array of strings, but then the idea was to load up the latest file in a pic box, so maybe an array of file objects? Does that seem like a backwards way of going forwards? I just wondered if anyone had any ideas of an easier way to store this kind of list of information in vb.net, i've just recently moved from vb6 so you'll have to excuse my dumbness!
|
|
|
|
|
Hi,
I have managed to add WMP to aform in vb.net, however I'm not sure how to get it to play a video of my choosing. What i would like is that when the form opens, the user clicks on play and the video clip thats already on the system begins to play.
how do I do this?
Thanks.
|
|
|
|
|
Have you read the WMP docs ? There's a property, I suspect it's Url, that you set to the path of the file. There's anotehr property called ctl_controls ( from memory ), which has play, stop, etc methods on it.
Christian Graus - C++ MVP
|
|
|
|
|
Hi,
Thanks forthe response, Ive changed the URL to the video i want to play,but it doesnt play it, ive also changed the ctl control properties, but still no result.
where do i get the WMP docs from?
Thanks
Jaidev
|
|
|
|
|
|
Hi
Is there as easy way to display row numbers in a DataGridView Control (i.e. in the Row Header cells on the side of the control) which has a DataTable as it's datasource. Also, if a row is deleted, it should re-number the rows
Tks
Richard
|
|
|
|
|
Hi
How can I get a list of SQL Servers on a network, and the databases on each server
Tks
|
|
|
|
|
May i know wat is the syntax to use to get the current date and current time. Sometime like that:
Date = CurrentDate
time = CurrentTime
it is urgent pls help...
|
|
|
|
|
Use DateTime.Today for just the date, and DateTime.Now for the date and time.
See here for more information.
|
|
|
|
|
And if i just wan the time only? btw wat should i add so tt the format of the date is 20-11-2006 and the time is 17:36?
|
|
|
|
|
For just the time, use DateTime.Now.ToShortTimeString .
And for the date, use DateTime.Now.ToShortDateString .
|
|
|
|
|
date = now or now.date
date = now.timeofday
nothing is impossible.....
|
|
|
|
|
I'm trying to read a wav file apply a filter to it and save that as a new wav file. I've had no problems doing that but when I try to play the new wav file in Windows Media Player (or any other player for that matter) I keep getting this error: C00D1199: Cannot play the file.
I took a look at the the headers for the original file and the new file and they are completely identical so that doesn't seem to be the problem. Also when I look at the files in the "mycomputer" file manager they have the same size (as they should be). Does anybody have any ideas on what could be the problem?
I will post the header file data below just incase that would be of any help.
,82,73,70,70
,210,19,1,0
,87,65,86,69
,102,109,116,32
,18,0,0,0
,1,0,1,0
,68,172,0,0
,136,88,1,0
,2,0,16,0
,0,0,102,97
,99,116,4,0
thanks,
Mike
|
|
|
|
|
You cannot just save a file as a .wav file. You have to convert it.
Have you tried playing your new Wave file in a different media player?
|
|
|
|
|
Yes I tried playing it in another player and got an error with that too.
What do you mean by converting it? I included the header information for it.
thanks you for your help.
|
|
|
|
|
MikeMarq wrote: What do you mean by converting it? I included the header information for it.
You cannot just save files, you must convert them. I'm not sure if this will help, but try looking here.
|
|
|
|
|
MikeMarq wrote: Yes I tried playing it in another player and got an error with that too.
In that case, your file is obviously corrupt.
Christian Graus - C++ MVP
|
|
|
|
|
If you treat that data as the header, and the rest as data, you have clearly corrupted the file.
That is the header (12 bytes), the "fmt " chunk (26 bytes) and half of the "fact" chunk (6 of 12 bytes).
---
b { font-weight: normal; }
|
|
|
|
|
Yes my header is 44 bytes long and includes all that information you meantioned. And the original file that I am filtering had the exact same header and was produced by another program and has no problems.
ps the commas are not actually in the header I just added them automatically when I read the data from the wav file.
thanks for your help
Mike
|
|
|
|
|
MikeMarq wrote: Yes my header is 44 bytes long
No, it's not. The header is 12 bytes long. What you have there is the header and one and a half data chunk. If you treat the rest of the file as sound data, you will be corrupting the other half of the second chunk and all the other chunks in the file, including the chunk that contains the actual sound data.
You should read up on the file format before you try to use it. The file is not at all arranged the way that you think it is.
---
b { font-weight: normal; }
|
|
|
|
|
Thank you that would explain why I have been having problems. I must be reading the wrong websites because that's where I got the 44 bytes from.
thanks,
Mike
|
|
|
|
|
I see. Yes, there is a 44 byte "header" that you can use when converting raw sample data into a wav file, but you can not assume when you read a wav file that it uses that exact format.
The 44 byte "header" consists of a 12 byte header, a 24 byte 'fmt ' chunk, and the first 8 bytes of the 'data' chunk. The rest of the 'data' chunk is the sound data, so by appending that you complete the 'data' chunk.
---
b { font-weight: normal; }
|
|
|
|
|
I have a program whereby the user adds items to a checked list box. Slowly the checkbox fills up with items. What I want to know is, when the program is shutdown, how do i save all the items in the list box to a setting or a location or a text file or something. My exit button is btnExit, the checkedlistbox is called clblist.
Thanks in advance for your help.
Posted by The ANZAC
|
|
|
|
|
One way would be to write code for this on the ButtonClick or FormClosing event or something similar. You could save the items to an app.config file (which I think may prove to be unwieldly) or to a plain old xml file.
|
|
|
|