Share via


IVsThreadedWaitDialog.GiveTimeSlice Method

Allows updating the text in the dialog, and checks if the user has cancelled the wait.

Namespace:  Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop.8.0 (in Microsoft.VisualStudio.Shell.Interop.8.0.dll)

Syntax

'Declaration
Function GiveTimeSlice ( _
    bstrUpdatedWaitMessage As String, _
    bstrIfTruncateAppend As String, _
    fDisableCancel As Integer, _
    <OutAttribute> ByRef pfCancelled As Integer _
) As Integer
int GiveTimeSlice(
    string bstrUpdatedWaitMessage,
    string bstrIfTruncateAppend,
    int fDisableCancel,
    out int pfCancelled
)
int GiveTimeSlice(
    [InAttribute] String^ bstrUpdatedWaitMessage, 
    [InAttribute] String^ bstrIfTruncateAppend, 
    [InAttribute] int fDisableCancel, 
    [OutAttribute] int% pfCancelled
)
abstract GiveTimeSlice : 
        bstrUpdatedWaitMessage:string * 
        bstrIfTruncateAppend:string * 
        fDisableCancel:int * 
        pfCancelled:int byref -> int
function GiveTimeSlice(
    bstrUpdatedWaitMessage : String, 
    bstrIfTruncateAppend : String, 
    fDisableCancel : int, 
    pfCancelled : int
) : int

Parameters

  • bstrUpdatedWaitMessage
    Type: String

    [in] The updated wait message. Can be nulla null reference (Nothing in Visual Basic).

  • bstrIfTruncateAppend
    Type: String

    [in] Can be nulla null reference (Nothing in Visual Basic), should be a short string e.g. L"..." or L"...\""

  • fDisableCancel
    Type: Int32

    [in] Disable the button if the operation can no longer be cancelled.

  • pfCancelled
    Type: Int32%

    [out] Returns true if the operation was cancelled.

Return Value

Type: Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Remarks

COM Signature

From vsshell80.idl:

HRESULT IVsThreadedWaitDialog::GiveTimeSlice(
   [in] BSTR bstrUpdatedWaitMessage, 
   [in] BSTR bstrIfTruncateAppend, 
   [in] BOOL fDisableCancel, 
   [out] BOOL *pfCancelled
);

.NET Framework Security

See Also

Reference

IVsThreadedWaitDialog Interface

Microsoft.VisualStudio.Shell.Interop Namespace