Hex Editor
Hex Editor - Binary File Editing Software for Windows

IMultiSelection.Count Property

HHD Software - Hex Editor Serial Port Monitor USB Protocol Analyzer Network Monitor
 
 
 
< PreviousTopNext >
Declaration
Getting property value:
Automation:
ulong  value = obj.Count;
Native (C++):
HRESULT  get_ Count ( [out, retval]   unsigned __int64 *  pCount) ;
Parameters
pCountPointer to a variable that receives a property value.
Return Value
Automation:The number of ranges in a selection object.Native: S_OK or standard OLE error code.
Remarks
Returns the number of ranges in a selection object. Complexity: constant-time.
Examples

Using the Count property

JavaScriptCopy Code
var fdoc = new ActiveXObject("FileDocument.FileDocument");
var msel = fdoc.CreateEmptySelection();
alert(msel.Count); // displays "0"
msel.AddRange(100, 20);  // selection: [100..120)
alert(msel.Count); // displays "1"
msel.AddRange(150, 20);  // selection: [100..120) U [150..170)
alert(msel.Count); // displays "2"
msel.AddRange(80, 80); // selection: [80..170)
alert(msel.Count); // displays "1"
    
< PreviousTopNext >
Copyright © 2012 HHD Software. All rights reserved.