This make it hard of course to attach the Control to the parent window.Ĭontributions : Firewall Log Analyzer for XP - Creating COM objects without a need of DLL's - UPnP support in AU3 Crystal Reports Viewer - PDFCreator in AutoIT - Duplicate File Finder SQLite3 Database functionality - USB Monitoring - Reading Excel using SQL Run Au3 as a Windows Service - File Monitor - Embedded Flash Player Dynamic Functions - Control Panel Applets - Digital Signing Code - Excel Grid In AutoIT - Constants for Special Folders in Windows Read data from Any Windows Edit Control - SOAP and Web Services in AutoIT - Barcode Printing Using PS - AU3 on LightTD Webserver MS LogParser SQL Engine in AutoIT - ImageMagick Image Processing - Converter Dec - Hex - Bin - Email Address Encoder - MSI Editor - SNMP - MIB Protocol Financial Functions UDF - Set ACL Permissions - Syntax HighLighter for AU3 ADOR.RecordSet approach - Real OCR - HTTP Disk - PDF Reader Personal Worldclock - MS Indexing Engine - Printing Controls GuiListView - Navigation (break the 4000 Limit barrier) - Registration Free COM DLL Distribution - Update - WinRM SMART Analysis - COM Object Browser - Excel PivotTable Object - VLC Media Player - Windows LogOnOff Gui - Extract Data from Outlook to Word & Excel - Analyze Event ID 4226 - DotNet Compiler Wrapper - Powershell_COM - NewĮxpand collapse popup #include-once Local Const $VLCPlayListInsert = 1 Local Const $VLCPlayListReplace = 2 Local Const $VLCPlayListAppend = 4 Local Const $VLCPlayListGo = 8 Local Const $VLCPlayListInsertAndGo = 9 Local Const $VLCPlayListReplaceAndGo = 10 Local Const $VLCPlayListAppendAndGo = 12 Local Const $VLCPlayListCheckInsert = 16 $oMyError = ObjEvent ( "AutoIt.Error", "MyErrFunc" ) $oVLC = ObjCreate ( "VideoLAN.VLCPlugin.1" ) _VLC _Startup ( ) $tFile = FileOpenDialog ( "Select media", "", "All files (*.*)" ) If $tFile "" Then _VLC _OpenFile ( $tFile ) Else Exit EndIf //Demo _VLC _Play ( ) Sleep ( 5000 ) _VLC _Pause ( ) Sleep ( 3000 ) _VLC _Play ( ) _VLC _SetVolume ( 5 ) Sleep ( 5000 ) _VLC _SetVolume ( 100 ) Sleep ( 2500 ) _VLC _SetVolume ( ) Sleep ( 2500 ) _VLC _Stop ( ) Func _VLC _Startup ( $_VLC_AutoLoop = 0, $_VLC_AutoPlay = 0, $_VLC_Visible = 1, $_VLC_Volume = 50 ) With $oVLC. The VLC Player creates some kind of own GUI and Control when calling the Object. The only way to get it run without crashing is NOT to use the "GUICtrlCreateObj". helpcontext _ ) SetError ( 1 ) to check for after this function returns Endfunc helpfile & & _ "err.helpcontext is: " & & $oMyError. source & & _ "err.helpfile is: " & & $oMyError. scriptline & & _ "err.source is: " & & $oMyError. lastdllerror & & _ "err.scriptline is: " & & $oMyError. windescription & & _ "err.number is: " & & $HexNumber & & _ "err.lastdllerror is: " & & $oMyError. description & & _ "err.windescription:" & & $oMyError. number, 8 ) Msgbox ( 0, "AutoItCOM Test", "We intercepted a COM Error !" & & & _ "err.description is: " & & $oMyError. Volume = 50 EndWith EndFunc Func GUIeventClose ( ) Exit EndFunc =>GUIeventClose This is custom error handler Func MyErrFunc ( ) $HexNumber = hex ( $oMyError. AddTarget ($hFile, Default, $VLCPlayListInsert, 0). " ) Return Else Sleep ( 100 ) _StartPlay ( $File ) EndIf EndFunc Func _StartPlay ( $hFile ) With $oVLC. ", 10, 20, 70 ) GUICtrlSetOnEvent ( - 1, "_SelectFile" ) $oVLC_Object = GUICtrlCreateObj ($hGui, 10, 70, 700, 460) GUICtrlSetStyle ( $oVLC_Object, $WS_VISIBLE ) GUICtrlSetResizing ($oVLC_Object,$GUI_DOCKAUTO) $GUI_DOCKAUTO Auto Resize Object GuiSetState ( ) $size = WinGetPos ( "" ) While 1 Sleep ( 100 ) WEnd Func _SelectFile ( ) $File = FileOpenDialog ( "Select a movie File ", & "", "Images (*.flv *.swf *.wmv *.avi *.*)", 1 ) If Then MsgBox ( 4096, "", "No File chosen. Expand collapse popup opt ( "GUIOnEventMode", 1 ) #include #include #include VLCPlaylistMode Const $VLCPlayListInsert = 1 Const $VLCPlayListReplace = 2 Const $VLCPlayListAppend = 4 Const $VLCPlayListGo = 8 Const $VLCPlayListInsertAndGo = 9 Const $VLCPlayListReplaceAndGo = 10 Const $VLCPlayListAppendAndGo = 12 Const $VLCPlayListCheckInsert = 16 Initialize error handler $oMyError = ObjEvent ( "AutoIt.Error", "MyErrFunc" ) - Declare objects - $oVLC = ObjCreate ( "VideoLAN.VLCPlugin.1" ) - Main Gui - $hGui = GuiCreate ( "VLC Viewer", 500, 390 ,- 1, - 1, Bitor ( $WS_OVERLAPPEDWINDOW, $WS_VISIBLE, $WS_CLIPSIBLINGS ) ) GUISetOnEvent ( $GUI_EVENT_CLOSE, "GUIeventClose" ) $bSelect = GUICtrlCreateButton ( "Select.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |