Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Checking which row is selected
Hi
I have some simple VB wich is going to paste 7 rows of a template report into a sheet. The nurse is going to be able to paste a blank reporting template before another to keep them in alpabetical order... I need to know that the activecell is multipliers of 8 eg a8 or b16 or d24 a32 etc etc so they can run the macro to paste the 7 rows plus one row as space into the report without overlaping the pervious report how could I do this? I was pondering if I could devide the number eg 32 and get a true / false As long as it was true I know its a mulitplier of 8 any other idears? cheers JOhn |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Checking which row is selected
Use MOD:
Sub sonic() n = Application.InputBox("enter a number: ") If n Mod 8 = 0 Then MsgBox ("divisible by 8") Else MsgBox ("not divisible") End If End Sub -- Gary''s Student - gsnu2007 "John in Wembley" wrote: Hi I have some simple VB wich is going to paste 7 rows of a template report into a sheet. The nurse is going to be able to paste a blank reporting template before another to keep them in alpabetical order... I need to know that the activecell is multipliers of 8 eg a8 or b16 or d24 a32 etc etc so they can run the macro to paste the 7 rows plus one row as space into the report without overlaping the pervious report how could I do this? I was pondering if I could devide the number eg 32 and get a true / false As long as it was true I know its a mulitplier of 8 any other idears? cheers JOhn |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Spell Checking with checking cell notes | Excel Discussion (Misc queries) | |||
checking if user selected cells are within a specified range of ce | Excel Programming | |||
Checking range of cells for entry then checking for total | Excel Programming | |||
Checking to see if a button is selected | Excel Programming | |||
Checking to see if user selected an Option | Excel Programming |