Noel Power wrote:
While not involved with reference parsing, I do know that for say the
example range like "Sheet1!A1" currently code that Jody popped into the
vba interop api to help me ( for various range XL/R1C1 support )
expects SCA_VALID to be set on return
From your comments below it would seem you imply SC_VALID getting set
for a single reference is not VALID ( pardon the pun ), and that causes
subsequent problems correct?
Yes, it causes an incomplete double reference when compiling a formula.
The parsing code ( or at least the call to the parse code ) that Jody
added for me always seems to expect SCA_VALID to be set ( and indeed
it's also passed as the mask )
e.g.
USHORT nMask = SCA_VALID;
rResFlags = rCellRanges.Parse( sAddress, pDoc, nMask, eConv, 0
);
if ( rResFlags & SCA_VALID )
return true;
return false;
So with respect to the SCA_VALID flag, I can live with a different
return value that can indicate success. But I would worry though that
SC_VALID is indeed required in a non obvious way ( there are many
strange xl addressing edge cases ), care would be required I think
changing this.
ScRangeList::Parse does its own handling of single-cell ranges anyway
(but doesn't take different conventions into account). To parse single
or double reference into a ScRange, there's ScRange::ParseAny, which
should probably also be used in ScRangeList::Parse. Anyway, if you only
use ScRangeList, the change shouldn't hurt you.
I could test any changes against my current ( not exhaustive but better
than nothing ) addressing tests ( that at least exercise this code a
little ) p.s. this week is not good though
For the other scenario you mention nothing immediately comes to mind.
I'll do the change on the xmlfilter02 CWS.
Niklas
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]