Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default Referencing Excel Cells

Hi Guys
Very new to VBA - can anyone help?
I need to reference a value (which might change) in cell F5 in some VBA
code.
For example I need to say . .. If (the value of F5) is StartDate Then
....
Thanks
MarkvdH

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 510
Default Referencing Excel Cells

Hi,

Dim StartDate As Date

If Range("F5").Value StartDate Then
your code
Else
your code
End If

HTH
Cheers
Carim

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default Referencing Excel Cells

Hi Carim
Thanks for your help
MarkvdH


Carim wrote:
Hi,

Dim StartDate As Date

If Range("F5").Value StartDate Then
your code
Else
your code
End If

HTH
Cheers
Carim


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
referencing cells based on conditions in other cells mirskman Excel Discussion (Misc queries) 1 January 29th 09 09:57 PM
Referencing the same cells Kenton Excel Discussion (Misc queries) 6 November 25th 08 09:57 PM
How do I save an Excel workbook so that cells referencing another. williejoeshaver Excel Discussion (Misc queries) 1 March 11th 05 09:44 PM
Referencing cells to VB Bob Phillips[_6_] Excel Programming 4 July 9th 04 06:21 PM
Referencing Cells in VB Brian McGuire Excel Programming 3 January 16th 04 08:14 PM


All times are GMT +1. The time now is 02:40 AM.

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"