HISHORT - Extract the high order signed short from a long value

Top  Previous  Next

Syntax

<shortResult> := HISHORT( <longValue> )

Parameters

<longValue>

 

The LONG value to extract the high order SHORT from.

Resulting Code

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

Description

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

Classification

Core

Category

Value Analysis Macros

Quick Info

Library: cckptcor.lib / cckptcor.dll

Header: windef.ch

See also

LOSHORT, HIWORD

Example

 

#INCLUDE "CockpitCoreLibs.ch"

#INCLUDE "windef.ch"

 

FUNCTION Main

 

* This will display the value -1

? HISHORT( Ulong2Long(0xFFFFFFFE) )

 

RETURN NIL