LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,726
Default Converting to late binding (for compatibility)

Late binding only makes sense in automation. If you are trying to access
Excel from within Excel (VBA) then late binding is pointless, you are
already bound to Excel.

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



wrote in message
ups.com...
Thanks Bob,

I checked this link out but I'm not sure if I understand how to apply
its methods in Excel. My guess would be something like this:

Sub ApplyCommonFormat(MyRange As String, Optional IgnoreBottomRow As
Boolean)

Dim objSheet as Object

Set objSheet = CreateObject("Excel.Worksheet")

With objSheet.Range(MyRange)

With .Borders(xlEdgeLeft)
.Color = 0
.Weight = xlThin
End With
With .Borders(xlEdgeTop)
.Color = 0
.Weight = xlThin
End With
With .Borders(xlEdgeRight)
.Color = 0
.Weight = xlThin
End With
.HorizontalAlignment = xlCenter

End With

If IgnoreBottomRow = False Then
With ActiveSheet.Range(MyRange).Offset(rowoffset:=1)
With .Borders(xlEdgeTop)
.Color = 0
.Weight = xlThick
End With
End With
End If

End Sub

Would this be right?

Tristan



 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
late binding Michelle Hanan Excel Programming 2 January 25th 07 03:28 AM
Late Binding to a dll XLW Excel Programming 0 August 28th 06 06:43 PM
Help converting code to late binding XP Excel Programming 2 February 16th 06 05:51 PM
Late Binding examples of binding excel application HeatherO Excel Programming 13 March 17th 05 08:19 AM
EARLY binding or LATE binding ? jason Excel Programming 6 February 26th 04 04:57 PM


All times are GMT +1. The time now is 10:23 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"