Formatting Excel through VBA Coding

  • Thread starter Thread starter caldog
  • Start date Start date
C

caldog

I have code that clears certain data, when I click on a button, the coding is
"Selection.Delete Shift:=xlUp".

I then want to be be able to re-establish my borders, my word font type, and
word font size, by way of some VBA coding.

I have struggled with the For-Next Loop coding, but alas all of the cells
remain blank after going through through the For-Next routine.

I'm sure there is a simple coding for this, but I sure have found it as of
yet.

Thanks for reading
 
I forgot to include in my other message, that what I am trying to do is the
range of B8 through B57. Will not go higher then row 8, but I could go lower
if the need is there.
 
Hi caldog,
Try Selection.ClearContents, that way you won't have to reformat.
Otherwise if you wish to continue as you are just record a macro of youself
doing the formatting and run that.
 
If desired, send your file to my address below along with this msg and
a clear explanation of what you want and before/after examples.
 
Don,

Thanks for the reply. With what Normek suggested, and a little trial and
error on my part, I was able to get what I was after. Everything is now
working just fine.
 
Back
Top