Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default 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   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default 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
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Spell Checking with checking cell notes jfitzpat Excel Discussion (Misc queries) 0 August 8th 07 10:26 PM
checking if user selected cells are within a specified range of ce rockhammer Excel Programming 4 June 4th 07 07:41 PM
Checking range of cells for entry then checking for total Barb Reinhardt Excel Programming 1 October 13th 06 02:47 PM
Checking to see if a button is selected cheaperThanAPro[_4_] Excel Programming 4 October 22nd 05 12:44 AM
Checking to see if user selected an Option Kirk[_2_] Excel Programming 1 August 27th 03 09:46 PM


All times are GMT +1. The time now is 06:22 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"