Important: The information in this document is obsolete and should not be used for new development.
ShortenDITL
To remove items from an existing dialog box while your application is running, use theShortenDITL
procedure.
PROCEDURE ShortenDITL (theDialog: DialogPtr; numberItems: Integer);
theDialog
- A pointer to a dialog record.
numberItems
The number of items to remove (starting from the last item in the item
list resource).DESCRIPTION
TheShortenDITL
procedure removes the specified number of items from the dialog box. This procedure is especially useful if several dialog boxes share a single item list resource, because you can useShortenDITL
to remove items as necessary for individual dialog boxes.You typically create an invisible dialog box, call the
ShortenDITL
procedure, then make the dialog box visible by using the Window Manager procedureShowWindow
. Note thatShortenDITL
does not automatically resize the dialog box; you can use
the Window Manager procedureSizeWindow
if you need to resize the dialog box.SPECIAL CONSIDERATIONS
TheShortenDITL
procedure is available in System 7 and in earlier versions of the Communications Toolbox. Before callingShortenDITL
, you should make sure that it
is available by using theGestalt
function with thegestaltDITLExtAttr
selector. Test the bit indicated by thegestaltDITLExtPresent
constant in theresponse
parameter. If the bit is set, thenShortenDITL
is available.SEE ALSO
You can use theCountDITL
function, described next, to determine the number of items in the dialog box's item list resource. See the chapter "Window Manager" in this book
for information on theShowWindow and SizeWindow
procedures. TheGestalt
function is described in the chapter "Gestalt Manager" in Inside Macintosh: Operating System Utilities.