SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Member
    Join Date
    Feb 2011
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Between 2 Number

    Hi There,

    I have two numbers 100 and 200

    so if the number = between 100 and 199 then do this code

    or

    if the number = between 200 and 299 then do this code.

    Any ideas

    Thanks

  2. #2
    Just Blow It bronze trophy
    DaveMaxwell's Avatar
    Join Date
    Nov 1999
    Location
    Mechanicsburg, PA
    Posts
    7,290
    Mentioned
    122 Post(s)
    Tagged
    1 Thread(s)
    You mean besides the simplest?
    Code ASP:
    <%
    if lngNumber >= 100 and lngNumber <= 199 then
        Response.Write "In block 100-199"
    elseif lngNumber >= 200 and lngNumber <= 299 then
        Response.Write "In block 200-299"
    end if
    %>
    Dave Maxwell - Manage Your Site Team Leader
    My favorite YouTube Video! | Star Wars, Dr Suess Style
    Learn how to be ready for The Forums' Move to Discourse


Tags for this Thread

Bookmarks

Posting Permissions

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