Shell.RefreshMenu method

Refreshes the contents of the Start menu. Used only with systems preceding Windows XP.

Syntax


Shell.RefreshMenu() As Integer

Parameters

This method has no parameters.

Remarks

The functionality that RefreshMenu provides is handled automatically under Windows XP or later. Do not call this method under that operating system.

Examples

The following example shows RefreshMenu in use. Proper usage is shown for JScript, VBScript, and Visual Basic.

JScript:


<script language="JScript">
    function fnShellRefreshMenuJ()
    {
        var objShell = new ActiveXObject("shell.application");
        
        objShell.RefreshMenu();
    }
</script>


VBScript:


<script language="VBScript">
    function fnShellRefreshMenuVB()
        dim objShell
        
        set objShell = CreateObject("shell.application")
        objShell.RefreshMenu

        set objShell = nothing
    end function
 </script>


Visual Basic:


Private Sub fnShellRefreshMenuVB()
    Dim objShell As Shell
    
    Set objShell = New Shell
    objShell.RefreshMenu

    Set objShell = Nothing
End Sub


Requirements

Minimum supported client

Windows 2000 Professional, Windows XP [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Shldisp.h

IDL

Shldisp.idl

DLL

Shell32.dll (version 4.71 or later)

 

 

Community Additions

ADD
Show:
© 2014 Microsoft