質問

i'm trying to print a record in NVelocity based on certain condition:

Below is the snippet... basically, Loop through the Addresses Object and if the current AdType is the "Current Address", print it and then exit out of the loop ...

I'm getting "#break" in my output html... as if it is ignoring it..

I have version 1.1.1 of NVelocity

Thanks

     #foreach($spAddress in $Report.Spouse.Addresses)
         #if( $spAddress.AdType == "Current Address")
    <tr>
        <td width="23%">
            <font size="2"><strong>$spAddress.AdType :</strong></font>
        </td>
        <td width="75%">
            <font size="2">$spAddress.CivicNumber, $spAddress.StreetName,$spAddress.City, $spAddress.Province, $spAddress.PostalCode</font>
        </td>
    </tr>
        #break
        #end
    #end

正しい解決策はありません

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top