[Date Prev][Date Next] [Thread Prev][Thread Next]
[Date Index] [Thread Index] [New search]

RE: How to identify a Table Row Selection




>When the element selection fails you could try to inspect document's
>property FP_SelectedTbl and if it returns something useful inspect the
>selected cell range within this table. You can find more in the FDK
>Programmer's Guide, "Getting and setting IDs of selected tables and
>table rows" (on page 85).

That's where it breaks down.  
When I select the Table element and try:
	idSelection = F_ApiGetId(FV_SessionId, idDoc, FP_SelectedTbl);
I get zero (0) which is not very useful.
When I select the insertion point to be between the Row elements for a Row
selection I get the same result.  
I can get the ID for FP_FirstTblInDoc, but not for FP_SelectedTbl, so I know
that something is working, but not anything I can use.   Either the
documentation, the FDK or the structure of my document is not working
corrrectly.  And at this point I'm not sure where to look or how to diagnose
it.   

One thing that did look encouraging is that 
	propVal = F_ApiGetPropVal(FV_SessionId, idDoc, FP_ElementSelection);
returned a value for propVal.propVal.u.ival.  I'm still trying to figure out
if it means anything, however.

There's plenty of code in this component, that identifies Element selections
and let me walk the elements within.  But, I can't seem to get started on
doing that in a table row if I can't get a handle on the selection.

Chuck Vorndran

-----Original Message-----
From: Stefan Petrucha [mailto:petrucha@isnet.sk]
Sent: Tuesday, March 04, 2003 06:08
To: Vorndran, Charles P
Subject: Re: How to identify a Table Row Selection


"Vorndran, Charles P" wrote:

> When the selection is any element in the body of document, such as a
> list-item or a group of list-items, the F_ObjHandleT element ids are not
> NULL.  However, when the selection is a table row, all the F_ObjHandleT
> element ids are 0.  I've tried using the code snippet on page 119 of the
FDK
> 7.0 Programmer's Guide, to try and drill down to determine where in the
> table this range lives, and came up with "You are not in a table at all"
> 
> I know that table-rows are part of FO_Tbl and should themselves be
> identified as FO_Row.  But even to get there, I think I need to get a
handle
> for the selection before I can test for its type.

When the element selection fails you could try to inspect document's
property FP_SelectedTbl and if it returns something useful inspect the
selected cell range within this table. You can find more in the FDK
Programmer's Guide, "Getting and setting IDs of selected tables and
table rows" (on page 85).

Stefan Petrucha
-- 
Publishing Automation
& Technical Documentation
http://www.isnet.sk/petrucha

** To unsubscribe, send a message to majordomo@omsys.com **
** with "unsubscribe framers" (no quotes) in the body.   **