If Statement

Results 1 to 3 of 3

Thread: If Statement

  1. #1
    Corrina Guest

    Default If Statement

    I am writing a ASP page to obtain an order status for customers. I have everything working except one thing. I want to be able to break out a certain field that contains tracking numbers. If the order is shipped UPS, then I&#039;ll show one message...if it is shipped USPS, then I&#039;ll show a different message. So this is what I have so far:<BR><BR>Response.Write objRS("ShipTrackNo")<BR>If objRS("ShipTrackNo") = &#039;1Z%&#039; Then<BR> Response.write blah blah blah<BR>Elseif<BR> objRS("ShipTrackNo") = &#039;EL%&#039; Then<BR> response.write blah blah blah<BR>Endif<BR><BR>I get an error with this though. Am I using the incorrect wildcard? Or can I not use the = sign?<BR><BR>Thanks for any help!!!

  2. #2
    Join Date
    Dec 1969

    Default RE: If Statement

    try <BR>if left(objrs("ShipTrackNo"),2)="1Z" then<BR> Response.write blah blah blah<BR>elseif left(objrs("ShipTrackNo"),2)="EL" then<BR> Response.write blah blah blah

  3. #3
    Corrina Guest

    Default RE: If Statement

    Thanks so much!! It worked!!! That rocks!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts