Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Dec 2002
    Location
    Washington State
    Posts
    98
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Simple Math Value question...

    What I am trying to figure out is how to do something like this:

    Code:
    If Value1 > Value2,Value3,Value4,Value5 THEN this...
    else If Value2 > Value1,Value3,Value4,Value5 THEN this...
    else If Value3 > Value1,Value2,Value4,Value5 THEN this...
    else If Value4 > Value1,Value2,Value3,Value5 THEN this...
    else If Value5 > Value1,Value2,Value3,Value4 THEN this...
    Any comments or suggestions would be appreciated. Thanks.


    ~Isaac~
    ~ Isaac Lloyd ~
    Website Design & Development
    http://www.IsaacLloyd.com

  • #2
    New Coder
    Join Date
    Dec 2002
    Location
    Washington State
    Posts
    98
    Thanks
    0
    Thanked 0 Times in 0 Posts
    fixed my own question. Thanks anyways.

    Code:
    <%
    
    Dim Value1, Value2, Value3, Value4, Value5
    
    Value1 = 111
    Value2 = 5
    Value3 = 30
    Value4 = 2
    Value5 = 100
    
    If Value1 > Value2 AND Value1 > Value3 AND Value1 > Value4 AND Value1 > Value5 Then
    Response.Write "VALUE1"
    
    ElseIf Value2 > Value1 AND Value2 > Value3 AND Value2 > Value4 AND Value2 > Value5 Then
    Response.Write "VALUE2"
    
    ElseIf Value3 > Value1 AND Value3 > Value2 AND Value3 > Value4 AND Value3 > Value5 Then
    Response.Write "VALUE3"
    
    ElseIf Value4 > Value1 AND Value4 > Value2 AND Value4 > Value3 AND Value4 > Value5 Then
    Response.Write "VALUE4"
    
    ElseIf Value5 > Value1 AND Value5 > Value2 AND Value5 > Value3 AND Value5 > Value4 Then
    Response.Write "VALUE5"
    
    Else
    
    END IF
    
    %>

    ~Isaac~
    ~ Isaac Lloyd ~
    Website Design & Development
    http://www.IsaacLloyd.com


  •  

    Posting Permissions

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