Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default VB excel help needed

I need to write a macro for excel to do the following.

If cell d(n) is "" the copy r(n) into d(n).

anyone know what sub needs to be written?

Cheers

EggHeadCafe - Software Developer Portal of Choice
COM+ Services Overhead in .NET
http://www.eggheadcafe.com/tutorials...erhead-in.aspx
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 236
Default VB excel help needed

Perhaps the description of what actually needs to be done could be a
bit better but from what you've posted - something like this could be
a start:

Sub PutOneCellValueIntoAnother()
Dim rngTarget as Range
'Here it's assumed that your d(n) is Range("A1") and your r(n) is
Range("A2").

Set rngTarget = Range("A1")

if rngTarget.value="" then rngTarget.value=Range("A2").value

End Sub

But as above - you'd need to describe better what you actually need to
get more meaningfull advices here.

On Nov 27, 2:48*pm, Robert Bloom wrote:
I need to write a macro for excel to do the following.

If cell d(n) is "" the copy r(n) into d(n).

anyone know what sub needs to be written?

Cheers

EggHeadCafe - Software Developer Portal of Choice
COM+ Services Overhead in .NEThttp://www.eggheadcafe.com/tutorials/aspnet/aab197cf-64da-4233-9819-0...


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
Excel Help Needed RICHCHAP New Users to Excel 1 September 2nd 09 12:07 PM
Excel help needed. Mr QA Man Excel Discussion (Misc queries) 2 April 14th 07 10:34 AM
ActiveX Plugin needed in Excel 2000 missing from Excel 2003 cadcam Excel Programming 0 July 13th 06 01:05 AM
help needed with excel 97 sithlord3k New Users to Excel 2 September 23rd 05 05:15 PM
VB code needed for running newer excel version macros in older excel versions Tom Excel Programming 6 October 16th 03 03:11 AM


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