Cocktail Help Reference
GetCurrent Method
See Also  Send Feedback
Cocktail Assembly > Cocktail Namespace > DialogHost Class : GetCurrent Method



source
The hosted ViewModel.

Glossary Item Box

Returns a reference to the dialog host if the provided ViewModel is currently hosted in the dialog host.

Syntax

Visual Basic (Declaration) 
Public Shared Function GetCurrent( _
   ByVal source As Caliburn.Micro.IChild _
) As IDialogHost
Visual Basic (Usage)Copy Code
Dim source As Caliburn.Micro.IChild
Dim value As IDialogHost
 
value = DialogHost.GetCurrent(source)
C# 
public static IDialogHost GetCurrent( 
   Caliburn.Micro.IChild source
)
C++/CLI 
public:
static IDialogHost^ GetCurrent( 
   Caliburn.Micro.IChild^ source
) 

Parameters

source
The hosted ViewModel.

Return Value

Null if the ViewModel is not currently hosted in a dialog host, otherwise a reference to the current dialog host.

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

© 2013 All Rights Reserved.