Storages & Files Clear
Clear method

Clears the contents of the SFShellLink object's properties. Then the object can be reused to manage/create another shortcut.

Syntax:

object.Clear

Examples:

Set link = Server.CreateObject("newObjects.utilctls.ShellLink")
Set sf = Server.CreateObject("newObjects.utilctls.SFMain")
    
link.Path = sf.GetSpecialPath(cGSPDesktopDirectory)
link.Name = "My Sample Link"
link.Target = "Notepad.exe"
link.Description = "My first shell link"
link.Arguments = Server.MapPath(Request.ServerVariables("SCRIPT_NAME"))
If link.Save Then
  Response.Write "Success"
Else
  Response.Write "Error"
End If
link.Clear
link.Path = sf.GetSpecialPath(cGSPDesktopDirectory)
link.Name = "My Second Sample Link"
link.Target = "Notepad.exe"
link.Description = "My second shell link"
If link.Save Then
  Response.Write "Success"
Else
  Response.Write "Error"
End If

Creates two shortcuts.

Applies to: SFShellLink object

Supported on:

Windows 95/NT and later

 

newObjects Copyright 2001-2006 newObjects [ ]