have you tried getting the specific field vs
the "*deep search"
CSpRepeated rep = (CSpRepeated) event.getSource();
CSpValue axleNum = rep.getDisplayFieldValue("txtAxle");
//check the length of the stringified CSpValue at this point...
-Chip
Team NetDynamics
"Mick Davis" <[EMAIL PROTECTED]> wrote:
>
>I'm sorry if this has been posted before but I cannot find the answer to this problem
>in the existing messages...
>
>
>I have a repeated that has fields that are bound to a dataobject. When the dataobject
>select executes and no rows are retrieved I am getting a blank row in the HTML. This
>behavior is explained in the documentation. However when I try to get the value of
>the
>textfields in the onBeforeRowDisplay to skip the display of the row I am getting
>results that I do not understand. I'm also using this event to gather information
>used
>to calculate a value for a statictext that is displayed on the same row.
>
>For the first row of the repeated my results are always blank. Not NULL, but blank.
>Am I doing something wrong here. Below is a snippet of code showing what I'm doing,
>The commented out code shows what I'm trying to accomplish when the row is truly
>blank.
>
>If anyone could help out with a code sample that works I would greatly appreciate it.
>I've been messing with this off and on for the past week and it's really irritating
>me.
>
>Thanks!
>
>Mick Davis
>
> public int rptWeight_onBeforeRowDisplayEvent(CSpDataDrivenVisualEvent event)
> {
> CSpValue axleNum = getDisplayFieldValue("*txtAxle");
> if (axleNum instanceof CSpNull)
> {
> if (CUtil.DEBUGSTAT) CUtil.debug("Axle num is null.");
> } else
> {
>// if (axleNum.stringValue().length() == 0)
>// {
>// return(SKIP);
>// }
> if (CUtil.DEBUGSTAT) CUtil.debug("Axle Num: " +
>axleNum.stringValue());
> }
>
>
> float PAL, vlw, nt, mw, vw;
> int mac;
> CSpFloat n;
> CSpString s;
> CSpValue v;
> CSpValue axleKey = getDisplayFieldValue("*txtAxle");
> if (axleKey instanceof CSpNull)
> {
> return(SKIP);
> } else
> // Calculate Pneumatic Axle Limit:
> // PAL = veh_and_load_weight div num_tires div mfg_width
>
> vlw = 0;
> try // ***** AXLE_VEH_LOAD_WGHT_LB *****
> {
> v = getDisplayFieldValue("*txtTotalWeight");
> if (CUtil.DEBUGSTAT) CUtil.debug("Total Weight = " +
>v.stringValue());
> if (!(v instanceof CSpNull))
> { vlw = v.floatValue(); }
> } catch (Exception e2)
> {
> vlw = 0;
> if (CUtil.DEBUGSTAT) CUtil.debug("vlw: Exception = " +
>e2);
> }
>
> nt = 0;
> try // ***** AXLE_NUMBER_OF_TIRES *****
> {
> v = getDisplayFieldValue("*txtNumTires");
> if (CUtil.DEBUGSTAT) CUtil.debug("Num Tires = " +
>v.stringValue());
> if (!(v instanceof CSpNull))
> { nt = v.floatValue(); }
>
_________________________________________________________________________
To unsubscribe from this mailing list please send an email to:
[EMAIL PROTECTED]
Please remember to use the same email address you subscribed with.
For help in using, subscribing, and unsubscribing to the discussion
forums, please go to: http://www.netdynamics.com/support/visitdevfor.html
For dire need help, email: [EMAIL PROTECTED]