View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Claus Busch Claus Busch is offline
external usenet poster
 
Posts: 3,872
Default Advice on multiple macros, same code just a different column

Hi again,

Am Fri, 14 Feb 2014 19:01:08 +0100 schrieb Claus Busch:

MyCol = Application.InputBox("Please enter a column character", _
"Column check", Type:=2)

If MyCol = "" Or MyCol = "False" Then Exit Sub

Start = Asc(MyCol) - 69 - (71 - Asc(MyCol)) * 6


check MyCol for the expected range (G:M):

If MyCol = "" Or MyCol = "False" Then Exit Sub
If Asc(MyCol) < 71 Or Asc(MyCol) 77 Then Exit Sub

Start = Asc(MyCol) - 69 - (71 - Asc(MyCol)) * 6


Regards
Claus B.
--
Win XP PRof SP2 / Vista Ultimate SP2
Office 2003 SP2 /2007 Ultimate SP2