<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Bernd, <div>Get rid of the 'then' in your 'if' statement -- it is not part of the 'if' clause syntax. </div><div>--Jennifer</div><div><br><div><div>On Oct 26, 2010, at 10:06 AM, Becker, Bernd wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div><br>dear all, <br>what is wrong with this?<br><br><br>ignore=(20101021)<br><br>in=0<br>while ( in < 1 )<br> in= in +1<br><br>* check current date against list of dates to be ignored:<br> dimfx = subwrd(ignore, in)<br> say rc' 'valnum(dimfx)<br> dimfx = math_format('%10.2f', dimfx )<br> ifxdate = math_format('%10.2f', fxdate )<br> skip=(ifxdate-dimfx)/1.<br>* this is zero to trigger skip<br> say rc' 'dimfx' 'ifxdate' 'skip ' 'valnum(skip) <br> if ( skip = int(0) ) then<br> say 'skip 'dimfx ' 'fxdate<br> else<br> say 'not skip 'dimfx ' 'fxdate<br><br><br>for the life of it, skip is always true! even if skip is anything but<br>zero!<br><br>What can I do to skip if skip =0?<br><br>Cheers,<br>Bernd.<br><br>--<br>Bernd Becker Climate Impacts Product Development<br>Met Office Hadley Centre FitzRoy Road Exeter Devon EX1 3PB United<br>Kingdom<br>Tel.: +44 (0) 1392 884511 Fax: +44 (0)870 900 5050<br>E-mail:<a href="mailto:bernd.becker@metoffice.gov.uk">bernd.becker@metoffice.gov.uk</a> -<br><a href="http://www.metoffice.gov.uk/research/our-scientists/seasonal-to-decadal/">http://www.metoffice.gov.uk/research/our-scientists/seasonal-to-decadal/</a><br>bernd-becker<br><br><br>_______________________________________________<br>gradsusr mailing list<br>gradsusr@gradsusr.org<br>http://gradsusr.org/mailman/listinfo/gradsusr<br></div></blockquote></div><br><div apple-content-edited="true"> <span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><div style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><div>--</div><div>Jennifer M. Adams</div><div>IGES/COLA</div><div>4041 Powder Mill Road, Suite 302</div><div>Calverton, MD 20705</div><div><a href="mailto:jma@cola.iges.org">jma@cola.iges.org</a></div><div><br class="khtml-block-placeholder"></div><br class="Apple-interchange-newline"></span></span></div></span> </div><br></div></body></html>