Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Find value and adress

Hi,

I have a large list of entries...In column A there is Date...Then I
have UserForm with Calendar. After selecting Date in form, I'd like to
find address of cell in column A with selected Date...

Why following doesn't work, required Date isn't found...

With Worksheets(1).Range("A:A")
Set c = .Find(Calendar1.Value)
If Not c Is Nothing Then
firstaddress = c.Address
' Do something
Else
' Do something else
End If

End With

Any help will be useful...
Thanks.


---
Message posted from http://www.ExcelForum.com/

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Find value and adress

This is just a guess as I don't use the calendar control myself.

Could it be that the value from calendar is only returned when you click on
a cell, and that afterwards, calendar.value is empty? If so, you would need
to save when clicking it, and then use that saved value to find the
corresponding value in A.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"acces " wrote in message
...
Hi,

I have a large list of entries...In column A there is Date...Then I
have UserForm with Calendar. After selecting Date in form, I'd like to
find address of cell in column A with selected Date...

Why following doesn't work, required Date isn't found...

With Worksheets(1).Range("A:A")
Set c = .Find(Calendar1.Value)
If Not c Is Nothing Then
firstaddress = c.Address
' Do something
Else
' Do something else
End If

End With

Any help will be useful...
Thanks.


---
Message posted from http://www.ExcelForum.com/



Reply
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
can i import an adress book Rick New Users to Excel 2 May 16th 10 05:06 PM
error with adress function denbee Excel Discussion (Misc queries) 2 July 16th 08 08:48 PM
Can Excel Adress Envelopes? Donald Excel Worksheet Functions 1 September 20th 06 07:52 PM
SUM using results from an Adress-formula Langbraten Excel Discussion (Misc queries) 3 March 31st 06 01:01 PM
Adress of Copied Range Luis Carrion Excel Programming 1 August 14th 03 04:05 AM


All times are GMT +1. The time now is 05:32 PM.

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

About Us

"It's about Microsoft Excel"