Merge and center

G

gr

Hi, I'm trying to give format to a Cell in Excel form
access. Can someone help me?

I have a text in cell A1 and trying to Merge and center
from A1 to D1.

I tried this statement but not working

gobjeExcel.Cells(1, "A:D").Align = xlPhoneticAlignCenter

Many thanks,
gr
 
B

Bernie Deitrick

gr,

With gobjeExcel.Range("A3:D3")
.HorizontalAlignment = xlCenter
.Merge
End With

HTH,
Bernie
MS Excel MVP
 
B

Bernie Deitrick

oooops!

That, of course, should be:

Range("A1:D1"), not Range("A3:D3")

Sorry about that,
Bernie
MS Excel MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top