#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default formula

Hello,
My macro contains the following formula:
With Worksheets("Entry Form").Range("K7")
.Formula = "=IF(ISBLANK(J7),"",AD7)"
End With
When i try to run it, it gives me a run-time error
(Application-defined or object-defined error).
What am i doing wrong?

Thanks for your help
Marta
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,885
Default formula

Hi
try
With Worksheets("Entry Form").Range("K7")
.Formula = "=IF(ISBLANK(J7),"""",AD7)"

--
Regards
Frank Kabel
Frankfurt, Germany


marta wrote:
Hello,
My macro contains the following formula:
With Worksheets("Entry Form").Range("K7")
.Formula = "=IF(ISBLANK(J7),"",AD7)"
End With
When i try to run it, it gives me a run-time error
(Application-defined or object-defined error).
What am i doing wrong?

Thanks for your help
Marta

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 863
Default formula

When you have embedded quotes in the formula, you must "double" them. The line
should read

.Formula = "=IF(ISBLANK(J7),"""",AD7)"


On Fri, 16 Jul 2004 12:56:00 -0700, "marta"
wrote:

Hello,
My macro contains the following formula:
With Worksheets("Entry Form").Range("K7")
.Formula = "=IF(ISBLANK(J7),"",AD7)"
End With
When i try to run it, it gives me a run-time error
(Application-defined or object-defined error).
What am i doing wrong?

Thanks for your help
Marta


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default formula

thank you!
-----Original Message-----
When you have embedded quotes in the formula, you

must "double" them. The line
should read

.Formula = "=IF(ISBLANK(J7),"""",AD7)"


On Fri, 16 Jul 2004 12:56:00 -0700, "marta"
wrote:

Hello,
My macro contains the following formula:
With Worksheets("Entry Form").Range("K7")
.Formula = "=IF(ISBLANK(J7),"",AD7)"
End With
When i try to run it, it gives me a run-time error
(Application-defined or object-defined error).
What am i doing wrong?

Thanks for your help
Marta


.

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
Commenting custom formula fields/formula on formula editor Muxer Excel Programming 2 July 24th 03 01:02 AM


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

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"