WR DELETE STYLESHEET

4D - Documentation   Français   English   German   4D Write, Command Theme List   4D Write, Command Alphabetical List   4D Write, Constant Theme List   Back   Previous   Next

version 6.5


WR DELETE STYLESHEET (area; stylesheetNum)

ParameterTypeDescription
areaLongint4D Write area
stylesheetNumLongintStylesheet number

Description

The WR DELETE STYLESHEET command deletes the style sheet whose number was passed in styleSheetNum from the 4D Write area referenced by area. .

Warning: System style sheets cannot be deleted. You can use the WR GET STYLESHEET INFO command to determine if the style sheet is protected from deletion.

Example

You want to delete each unprotected style sheets in your document:

   C_LONGINT(Area)
   C_INTEGER(NbStyleSheet;$SheetNum)
      `Counting number of style sheets
   NbStyleSheet:=WR Count(Area;wr nb stylesheets)
   $SheetNum:=1
   For ($i;1;NbStyleSheet)
      WR GET STYLESHEET INFO(Area;$SheetNum;$Name;$ApplyTo;$Protected;$Shortcut)
      If ($Protected=0)   `If the style sheet is not protected...
         WR DELETE STYLESHEET (Area;$SheetNum)
      Else 
         $SheetNum:=$SheetNum+1
      End if 
   End for

See also

WR CREATE STYLESHEET.


4D - Documentation   Français   English   German   4D Write, Command Theme List   4D Write, Command Alphabetical List   4D Write, Constant Theme List   Back   Previous   Next