Get Parts - Status Bar SENDMSG() Function 26

Syntax

PARTS$=SENDMSG(sysgui,id,26,int,string${,context{,ERR=lineref}})

Description

This function has a dual purpose.

  • If string$ is null, the int value is ignored and the returned string parts$ is a single byte indicating the number of segments within the status bar control.

  • If the string$ is not null, the returned string parts$ is a series of two-byte unsigned integers specifying the right edge location of the segments whose index is less than or equal to the int parameter. If the int parameter is greater than then number of segments, than all segments are returned. A segment which extends to the end of the status bar control returns a $FFFF$ for the right edge.

Parameter

Description

sysgui

SYSGUI channel.

id

Status bar control ID.

26

Number of this SENDMSG() function.

int

When the string$ is non-null, the int specifies how many segments to return for right edge locations.

string$

If string$ is null, the int value is ignored and the returned string parts$ is a single byte indicating the number of segments within the status bar control.

If the string$ is not null, the returned string parts$ is a series of two-byte unsigned integers specifying the right edge location of the segments whose index is less than or equal to the int parameter. If the int parameter is greater than the number of segments, then all segments are returned. A segment which extends to the end of the status bar control returns a $FFFF$ for the right edge.

Example

For a status bar with two segments, the following will return a four-byte string:

parts$=SENDMSG(sysgui,id,26,255,$00$)

The dec(parts$(1,2)) is the right edge of the first segment, and dec(parts$(3,2)) is the right edge of the second segment.