Thread: Spaced out
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
antinoz antinoz is offline
external usenet poster
 
Posts: 9
Default Spaced out

Hi Guys another Query for you to ponder.

Ok, So were in a Do loop counter = icellcounter

I check cell "A" & icellcounter to see if it is of format
NNANNNNNNN (numeric, Alpha) (cheers for prev on this)

if it is: in column "F" & icellcounter I concatonate cells B,C,D,E
I can concatenate the cells fine my problem is trying to put an & " "
(space)between each cell as the text runs into one another otherwise.

code so far: (haspattern is the function to check the cells pattern
returning a boolean (thanks SEB)

If (HasPattern(Range("A" & iCellCounter)) = True) Then
Range("F" & iCellCounter).Formula = _
"=" & "B" & CStr(iCellCounter) _
& "&C" & CStr(iCellCounter) _
& "&D" & CStr(iCellCounter) _
& "&E" & CStr(iCellCounter)

any help would be appreciated