i want to show a Message when "Component" are not installed
i also want to show a LINK to download "Component"
how can i display it

i know i can use a LINK in RICHTEXT ...
Moderator: Rathinagiri
Hi Jimmy,
Code: Select all
FUNCTION ShowMessage( cTitle, cMainMessage, cContent, cExpandedInfo, cFooter, nIcon, nFooterIcon )
LOCAL aConfig := Array( TDC_CONFIG )
LOCAL nButton, nRadioButton
LOCAL lVerificationFlagChecked := .F.
hb_default( @cTitle, "Vista TaskDialog" )
hb_default( @cMainMessage, "" )
hb_default( @cContent, "" )
hb_default( @cExpandedInfo, "" )
hb_default( @cFooter, "" )
hb_default( @nIcon, TD_INFORMATION_ICON )
hb_default( @nFooterIcon, 0 )
aConfig[ TDC_TASKDIALOG_FLAGS ] := TDF_ENABLE_HYPERLINKS
aConfig[ TDC_COMMON_BUTTON_FLAGS ] := TDCBF_OK_BUTTON
aConfig[ TDC_HWND ] := GetActiveWindow()
aConfig[ TDC_HINSTANCE ] := GetInstance()
aConfig[ TDC_MAINICON ] := nIcon
aConfig[ TDC_WINDOWTITLE ] := cTitle
aConfig[ TDC_MAININSTRUCTION ] := cMainMessage
IF !Empty( cContent )
aConfig[ TDC_CONTENT ] := cContent
ENDIF
IF !Empty( cExpandedInfo )
aConfig[ TDC_EXPANDEDINFORMATION ] := cExpandedInfo
aConfig[ TDC_EXPANDEDCONTROLTEXT ] := "Hide details"
aConfig[ TDC_COLLAPSEDCONTROLTEXT ] := "Show details"
ENDIF
IF !Empty( cFooter )
IF !Empty( nFooterIcon )
aConfig[ TDC_FOOTERICON ] := nFooterIcon
ENDIF
aConfig[ TDC_FOOTER ] := cFooter
ENDIF
aConfig[ TDC_CALLBACK ] := {|h,n,w,l| callback( h,n,w,l )}
RETURN win_TaskDialogIndirect0( aConfig, @nButton, @nRadioButton, @lVerificationFlagChecked )
STATIC FUNCTION callback( hWnd, nNotification, wParam, lParam )
LOCAL lResult := .F.
/*
To prevent the task dialog from closing, the application must return FALSE,
otherwise the task dialog is closed
*/
LOCAL hResp := { 1=>"OK", 2=>"CANCEL", 3=>"ABORT", 4=>"RETRY", 5=>"IGNORE", 6=>"YES", 7=>"NO", 8=>"CLOSE" }
SWITCH nNotification
CASE TDN_BUTTON_CLICKED
// wParam - an int that specifies the ID of the button or comand link that was selected
IF hb_HPos( hResp, wParam ) != 0
lResult := .T.
ENDIF
EXIT
CASE TDN_HYPERLINK_CLICKED
ShellExecute( hWnd, "open", lParam, , , SW_SHOW )
END SWITCH
RETURN lResult
will show a window like the one below: Hope it is helpful.ShowMessage( , 'This uses the "ShowMessage" function', ;
"Just use an additional parameter (optional) to add this extra text.", ;
"And another parameter for yet more text. And another parameter for the footer.", ;
'This is the footer with hyperlink <a href="www.hmgextended.com">MiniGUI Software Page</a>', , TD_INFORMATION_ICON )
thx for Answer and Sample