Topic Path: Symbol Reference > Classes > TIdStackDotNet Class > TIdStackDotNet Methods > HostToNetwork Method > HostToNetwork Method (Word)
ContentsIndexHome
PreviousUpNext
TIdStackDotNet.HostToNetwork Method (Word)

Converts a numeric value to its Network byte order representation.

function HostToNetwork(
    AValue: Word
): Word; override;
Parameters 
Description 
AValue 
Numeric value to convert to its Network byte order. 

AHostShort - Network byte order for the numeric value.

HostToNetwork is an overloaded function that implements the methods used to access the htons() and htonl() APIs for the protocol stack implementation. 

HostToNetwork is used to convert the numeric value in AValue from its platform-specific byte order to its Network byte order (Big-Endian). 

The return value is the numeric value in AValue converted to its Network byte order representation. 

HostToNetwork uses IPAddress.HostToNetworkOrder to convert the value.

Copyright 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Post feedback to the Indy Docs Newsgroup.