LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 134
Default problem with find in merged cells

I thought I had this VBA pretty under control, but this one is new to me.

set r = .Find(" - Open Positions ( August 03, 2007 )")

returns nothing even though there is cell with that value

The only peculiarity of that cell is that is merged with others

Is the find function not supposed to work for merged cells?

Thanks,

Antonio


Code and sheet follows:

Sub main()

Dim r As Range

Dim match_address As String


Dim st As String


st = Worksheets(1).Range("A3").Value



With Worksheets(1).Columns("A")



Set r = .Find(st)

If Not r Is Nothing Then

match_address = r.Address



End If

End With

End Sub


Sheet:

Average Credit Balance 51,608.69 51,608.69 0

- Open Positions ( August 03, 2007 )
Stocks
Symbol Open Quantity Mult Open Price Close Price Cost Basis Value Unrealized
P/L
EUR
CS -- 7,000 1 -- -- 28.25 197,750.00 --
EAD -- 8,000 1 -- -- 21.92 175,360.00 --
FPB -- 5,000 1 -- -- 54.71 273,550.00 --

 
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
Find range of merged cells mcphc Excel Programming 2 February 1st 07 09:37 AM
Find Merged Cells Mike Rogers Excel Discussion (Misc queries) 5 December 6th 06 12:24 AM
how can I find merged cells in a large xl-file tvanellen Excel Discussion (Misc queries) 5 May 8th 06 01:02 AM
find and demerge merged cells jeromek Excel Programming 1 November 27th 04 05:05 PM
merged cells problem Libby Excel Programming 1 May 8th 04 09:42 AM


All times are GMT +1. The time now is 10:59 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"