Export (0) Print
Expand All

AddElementSegment method

Creates an IElementSegment interface for an element in a markup container and adds the segment to the editable selection.

Syntax


HRESULT retVal = object.AddElementSegment(pIElement, ppISegmentAdded);

Parameters

pIElement [in]

Type: IHTMLElement

Pointer to an IHTMLElement interface that specifies the element to add to the selection.

ppISegmentAdded [out]

Type: IElementSegment

Address of a pointer to a variable that receives an IElementSegment interface pointer for the element segment added to the selection environment.

Return value

Type: HRESULT

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

The selection type (set with the ISelectionServices::SetSelectionType method) must be set to SELECTION_TYPE_Control before a call to ISelectionServices::AddElementSegment.

 

 

Community Additions

ADD
Show:
© 2014 Microsoft