public void ShowDialog(TargetFormatDlg Dialog,IWin32Window hWnd)
Public Sub ShowDialog( _ByVal Dialog As TargetFormatDlg, _ByVal hWnd As IWin32Window _)
public:void ShowDialog(TargetFormatDlg Dialog,IWin32Window^ hWnd)
Dialog
A TargetFormatDlg enumeration value that specifies which dialog to show.
hWnd
Value that specifies the dialog owner's window handle.
Displays the specified property's dialog. If the method fails, an error is raised. For more information, refer to the Error Codes.
using Leadtools;using Leadtools.MediaFoundation;using LeadtoolsMediaFoundationExamples.Fixtures;public bool _result = false;public CaptureCtrlForm _form = new CaptureCtrlForm();public void HasDialogExample(){// reference the capture controlCaptureCtrl capturectrl = _form.CaptureCtrl;try{// set a video device first, you should use your video device name hereif (capturectrl.VideoDevices["Analog"] == null)throw new Exception("No Analog audio device available");capturectrl.VideoDevices["Analog"].Selected = true;// select the WMV target formatTargetFormat tf = capturectrl.TargetFormats[TargetFormatType.WMV];tf.Selected = true;// The HasDialog method tells us that the control// can display the desired settings dialog.// check to see if the Profile dialog is availableif (tf.HasDialog(TargetFormatDlg.Profile)){// show the dialogtf.ShowDialog(TargetFormatDlg.Profile, _form);// set the result_result = true;}}catch (Exception){_result = false;}}
Imports LeadtoolsImports Leadtools.MediaFoundationImports LeadtoolsMediaFoundationExamples.FixturesPublic _result As Boolean = FalsePublic _form As CaptureCtrlForm = New CaptureCtrlForm()Public Sub HasDialogExample()' reference the capture controlDim capturectrl As CaptureCtrl = _form.CaptureCtrlTry' set a video device first, you should use your video device name hereIf capturectrl.VideoDevices("Analog") Is Nothing ThenThrow New Exception("No Analog audio device available")End Ifcapturectrl.VideoDevices("Analog").Selected = True' select WMV target formatDim tf As TargetFormat = capturectrl.TargetFormats(TargetFormatType.WMV)tf.Selected = True' The HasDialog method tells us that the control' can display the desired settings dialog.' check to see if the Profile dialog is availableIf tf.HasDialog(TargetFormatDlg.Profile) Then' show the dialogtf.ShowDialog(TargetFormatDlg.Profile, _form)' set the result_result = TrueEnd IfCatch e1 As Exception_result = FalseEnd TryEnd Sub
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document
