MOD - what is it and DO?

Results 1 to 5 of 5

Thread: MOD - what is it and DO?

  1. #1
    METEHAN Guest

    Default MOD - what is it and DO?

    What is do?<BR><BR>Set rsData = objwebsite.getStrategyPerformance(fn_cusip)<BR> counter = 0<BR> do while not rsData.EOF<BR> if (counter mod 2) = 0 then<BR> Response.Write("&#060;TR BGCOLOR=#D8EAF0&#062;")<BR> else<BR> Response.Write("&#060;TR&#062;")<BR> end if<BR><BR><BR>like here what is do?

  2. #2
    Join Date
    Dec 1969

    Default RE: MOD - what is it and DO?

    This is a cut and paste from MSDN...<BR><BR>"Used to divide two numbers and return only the remainder."<BR><BR>So in other words, it is making every other line a different color. Kind of like Greenbar (EEEEEEEK!!!!)<BR><BR><BR>HTH<BR><BR>Jerry

  3. #3
    Ian Stallings Guest

    Default RE: MOD - what is it and DO?

    The Mod operator divides two numbers and returns the remainder of that. So in the Loop (Do while..)statement above they divide the counter variable by two and if the remainder is 0 then it colors the line. Other wise the line is left with no color (or the bg color)<BR><BR>Does that make sense? If not I&#039ll try to explain further.

  4. #4
    Ian Stallings Guest

    Default One more thing..

    Here is the msdn reference for scripting. You can find a good language reference there. I use it all the time for syntax:<BR><BR><BR><BR>hope this helps :-)

  5. #5
    METEHAN Guest

    Default RE: One more thing..

    Thank you so much

Posting Permissions

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