Bug 46818 - Hyperlink function support for Formula Evaluation
Summary: Hyperlink function support for Formula Evaluation
Status: RESOLVED FIXED
Alias: None
Product: POI
Classification: Unclassified
Component: HSSF (show other bugs)
Version: 3.5-dev
Hardware: PC Windows XP
: P2 normal (vote)
Target Milestone: ---
Assignee: POI Developers List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-03-06 16:02 UTC by Wayne Clingingsmith
Modified: 2009-03-30 23:10 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Wayne Clingingsmith 2009-03-06 16:02:55 UTC
org.apache.poi.hssf.record.formula.functions.Hyperlink is not implemented yet

I think the result needing to be returned is just the hyperlink label...

Here is code I used fir this function

public class Hyperlink implements Function {

    public Eval evaluate(Eval[] operands, int srcRow, short srcCol) {
        if (operands.length < 2) {
            return ErrorEval.VALUE_INVALID;
        }
        ValueEval retval = null;
        try {
            retval = OperandResolver.getSingleValue(operands[1], srcRow, srcCol);
        } catch (EvaluationException e) {
            return e.getErrorEval();
        }
        return retval;
    }
}
Comment 1 Josh Micich 2009-03-30 23:10:08 UTC
Applied in svn r760343

(with some minor modifications)