LOSHORT - Extract the low order signed short from a long value

Top  Previous  Next

Syntax

<shortResult> := LOSHORT( <longValue> )

Parameters

<longValue>

 

The LONG value to extract the low order SHORT from.

Resulting Code

A call to BitShiftMaskSign using the proper parameters to retrieve the low order short from <longValue>.

Description

LOSHORT retrieves the low order SHORT from the LONG <longValue>. The extracted value is signed. If you want to extract an unsigned WORD value, use LOWORD.

Classification

Core

Category

Value analysis macros

Quick Info

Library: cckptcor.lib / cckptcor.dll

Header: windef.ch

See also

HISHORT, LOWORD

Example

 

#INCLUDE "CockpitCoreLibs.ch"

#INCLUDE "windef.ch"

 

FUNCTION Main

 

* This will display the value -2

? LOSHORT( 0x0FFFFFFE )

 

RETURN NIL