faillobi.blogg.se

Purebasic set audio output
Purebasic set audio output












  1. #Purebasic set audio output full#
  2. #Purebasic set audio output plus#
  3. #Purebasic set audio output windows 7#
  4. #Purebasic set audio output windows#

In any case - If you start a new forms project which should create a "Form1" and add a button (Button1), a ComboBox(Combobox1)Īnd a Multiline TextBox(TextBox1) then add this code, that may help you get started I don't quite agree with your logic about "just a one line MSDOS command" the "dir" function has been coded so that's all you have to do. Reed Kimble - "When you do things right, people won't be sure you've done anything at all"

#Purebasic set audio output windows#

This may be a bit slow due to waiting for DIR to execute, then waiting for the parsing, but it does get you your desired result without a ton of windows forms permissions. So this example executes the dir command like in your previous post, then parses the text result into a list of file paths. Result.Add(System.IO.Path.Combine(currentFolder, line.Substring(index).Trim)) If line.StartsWith( " Directory of ") ThenĮnd If If line.EndsWith(fileExtension) Then Dim index As Integer = line.LastIndexOf( " "c) Info.CreateNoWindow = True Dim process As = (info)ĭim input As System.IO.StreamWriter = process.StandardInputĭim output As System.IO.StreamReader = process.StandardOutputĮnd Function Private Function ParseFileNames( ByVal dirOutput As String(), ByVal fileExtension As String) As String()ĭim currentFolder As String = String.Empty Next End Sub Private Function GetDirOutput( ByVal dirParameters As String) As String()ĭim info As New Private Sub Button1_Click( ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Clickĭim dirOutput As String() = GetDirOutput( "c:\*.mp3 /s")įor Each line As String In ParseFileNames(dirOutput, "mp3") I'm asking for help purely because I believe this is (or should be) a simple/easy task - and that I shouldn't have to battle with changing complicated search file listers just to let the user find and play an MP3 from the hard drive. The filepath and then continuing the loop by simple exception handler code). It seems that Directory.GetFiles(searchpattern, startdirectory, option searchFolderDepth) doesn't properly work due to the exception which arises from the unathourised exception event (and which it then seems to be impossible of getting In good old DOS, it would take a line or two of using the DIR or Tree commands to find the files so I can't believe that it is so hard to I know I've d/l a couple of file listers but they are/seem highly complicated for what should be a very simple task. So it's really only step 6 (the one in bold lettering) that I need help with! BTW I can open, play, pause, stop and close any given mp3 file (withĪ correct path) no problem using the Win32 API. Trapping that exceptionĭoesn't seem to do anything useful as I can't continue the search loop (OR get the filename that is causing the exception and add it to the files listbbox) - and so can't get any filenames. I keep getting an unauthorized access exception. I've tried 100's of ways) seem to get a filelist of all the files in all the directories that match the criteria - that's the bit I keep getting stuck on. I can get a list of directories ok I can't

purebasic set audio output

Ok I can populate the drives combobox no problem. Closing the search form exits the application. The user closes the playing form and goes back to first form (i.e. The sequence for playing the file is: open, play (then any of pause, play, stop), close – note that close also stops the file first if it is currently

#Purebasic set audio output plus#

Plus an Edit Ok button which gets enabled if the user edits the ID3 v1 tags.

purebasic set audio output

#Purebasic set audio output full#

Once the files listbox is populated, clicking on a file in the listbox passes the full path of the selected file to another form which is opened and shows the ID3 v1 tags of the file in textboxes and also the obligatory open, play, pause, the full path of each individual file) are added to a listbox The allowed read access directories are added to a listbox of directories. The computer searchesĪll directories starting at root for any and all files matching the file extension. The user enters a file extension in a textbox. The user selects a drive to search using the comboxBox. The comboBox with a list of all logical drives that are of type fixed and are ready. A ‘start search’ button to initiate a search for the files. A textbox for holding the file extension. Create a form with three listboxes (one for accessibleĭirectories, one for accessible files, one for INACCESSIBLE directories and files), a drive combobox (for a list of drives). My algorithm is: Simple mutlimedia player algorithm: 1.

#Purebasic set audio output windows 7#

I've just recently started using VB.Net 2010 Express edition and Windows 7 Home Premium 圆4 and I'm trying to write a simple multimedia player.














Purebasic set audio output