Jump to content

Pause Play


Mehmet
 Share

Recommended Posts

Tek butonla nasıl pause play yapıyoruz

[codebox]


#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#Include <Sound.Au3>
$Form1 = GUICreate("~~Programlar2011~~.::MeHMeT::.", 819, 508, 193)
$pause = GUICtrlCreateButton("Pause", 548, 464, 132, 35)
$play = GUICtrlCreateButton("Play", 680, 464, 132, 35)
FileInstall("C:\Documents and Settings\USER\Desktop\resim.bmp", @TempDir & "\resim.bmp")
$PIC1 = GUICtrlCreatePic(@TempDir & "\resim.bmp", 176, 392, 345, 97)
FileInstall("C:\Documents and Settings\USER\Desktop\Ses.mp3", @TempDir & "\Ses.mp3")
Sleep(1000)
SoundPlay(@TempDir & "\Ses.mp3",0)
SoundSetWaveVolume(50)
GUISetState(@SW_SHOW)
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
FileDelete(@TempDir & "\resim.bmp")
FileDelete(@TempDir & "\Ses.mp3")
Exit

Case $play
SoundSetWaveVolume(50)

Case $pause
SoundSetWaveVolume(0)
EndSwitch
WEnd

[/codebox]
bu arada benim hazırladığım katılımsız aıo bir kısmını görmüş oldunuz bu sadece arayüzünden bir kesit :)

Edited by MeHMeTBeN
Link to comment
Share on other sites

[codebox]#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#Include <Sound.Au3>
$Form1 = GUICreate("~~Programlar2011~~.::MeHMeT::.", 819, 508, 193)
;~ $pause = GUICtrlCreateButton("Pause", 548, 464, 132, 35
$play = GUICtrlCreateButton("Pause", 680, 464, 132, 35)
FileInstall("C:\Documents and Settings\USER\Desktop\resim.bmp", @TempDir & "\resim.bmp")
$PIC1 = GUICtrlCreatePic(@TempDir & "\resim.bmp", 176, 392, 345, 97)
FileInstall("C:\Documents and Settings\USER\Desktop\Ses.mp3", @TempDir & "\Ses.mp3")
Sleep(1000)
SoundPlay(@TempDir & "\Ses.mp3",0)
SoundSetWaveVolume(50)
GUISetState(@SW_SHOW)
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
FileDelete(@TempDir & "\resim.bmp")
FileDelete(@TempDir & "\Ses.mp3")
Exit

Case $play
If GUICtrlRead($play) = "Pause" Then
GUICtrlSetData($play, "Play")
SoundPlay("")
Else
GUICtrlSetData($play, "Pause")
SoundPlay(@TempDir & "\Ses.mp3",0)
EndIf

EndSwitch
WEnd
[/codebox]

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...