Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Adjusting value based on even or odd number. 1

Status
Not open for further replies.

Gatorajc

MIS
Mar 1, 2002
423
0
0
US
I am trying to change a value based on if another variable is Even or Odd.


Mod1 = "KX"
ICD=25001 This variable changes

This is the part giving me problems. I know this would not work just showing what I want to do.

If (ICD=Odd) then
Mod1 = "KS"
End if

Much Thanks in advance.




AJ
[americanflag]

Do you feel lucky?


 
if ICD Mod 2 = 0 then
Mod1 = "KS"
else
Mod1 = "KX"
end if

This should do.
rsshetty.

It's always in the details.
 
sprry abt that. i got my Mod mixed up.

if ICD Mod 2 = 0 then
Mod1 = "KX"
else
Mod1 = "KS"
end if

This should do.
rsshetty.

It's always in the details.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top