Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Format excel from Access (borders in cells)

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
Hi,

I am sending some data from Access to Excel and would like to set some borders in some specific cells in Excel.

I have tried:
oSheet.Range("G" & intI).Borders(xlEdgeTop).LineStyle = xlContinuous
oSheet.Range("G" & intI).Borders(xlEdgeTop).Weight = xlThin
oSheet.Range("G" & intI).Borders(xlEdgeTop).ColorIndex = xlAutomatic

But Access does not take it, and I don't know where to find help.
Any ideas?

Thanks,

Herrman
 
Hi Herrman!

What you have looks good, but you might try this:

Dim strRange As String
strRange = "G" & Format(intI)

Then use strRange for your range.

hth Jeff Bridgham
bridgham@purdue.edu
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top