AutoHotkey Community

It is currently May 24th, 2012, 9:34 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: list of files
PostPosted: April 2nd, 2007, 5:09 pm 
Offline

Joined: February 19th, 2007, 9:03 am
Posts: 338
Location: Czech Republic
want make a mp3 player. In mp3 is button open, and play and button add to list. I need a code, which create a list of files, which user submit.
Thanks.
Pleae write this code.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: April 3rd, 2007, 1:21 am 
Offline

Joined: November 13th, 2004, 4:08 am
Posts: 2951
Location: Minnesota
You want to make an mp3 player? From what I'm seeing, it's more like you want someone to make an mp3 player for you. Why not just get Winamp or something?


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: April 3rd, 2007, 4:14 pm 
Offline

Joined: February 19th, 2007, 9:03 am
Posts: 338
Location: Czech Republic
I need a code, which add mp3 files to a listbox. oI have got a ther codes.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: April 3rd, 2007, 4:30 pm 
To get you started:
Code:
Loop %A_MyDocuments%\*.mp3
{
   mp3List .= A_LoopFileName . "|"
}
StringTrimRight mp3List, mp3List, 1
Gui Add, ListBox, w200 h300 vmp3Choice, %mp3List%
Gui Add, Button, w100 xm+50 gPlay Default, Play MP3
Gui Show
Return

Play:
   Gui Submit, NoHide
   If (mp3Choice = "")
   {
      MsgBox 16, Error, No File Selected!
   }
   Else
   {
      MsgBox Now playing %mp3Choice%
   }
Return

GuiClose:
GuiEscape:
ExitApp


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: April 3rd, 2007, 4:45 pm 
Offline

Joined: February 19th, 2007, 9:03 am
Posts: 338
Location: Czech Republic
In this code is any error.
Code:
Gui, 7:+owner1 
; Make the main window (Gui #1) the owner of the "about box" (Gui #2).
Gui +Disabled 
; Disable main window.
Loop %A_ScriptDir%\media\*.*
{
   mp3List .= A_LoopFilename . "|"
}
StringTrimRight mp3List, mp3List, 1
Gui 7:Add, ListBox, w200 h300 vmp3Choice, %mp3List%
Gui 7:Add, Button, w100 xm+50 g7Play Default, hrej
Gui, 7:Show, w65, oblíbené
Return
7play:
   Gui, 7:Submit, NoHide
   If (mp3Choice = "")
   {
      MsgBox 16, chyba, nebyl vybrán žádný soubor!
   }
   Else
{
SoundPlay, %mp3Choice%
   }
return
7GuiClose:
7GuiEscape:
Gui, 1:-Disabled 
Gui Destroy

Please write good code.


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: BrandonHotkey, Cerberus, janopn, Pulover, Xx7, Yahoo [Bot] and 68 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group