Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 83
Default De-link a cell reference in a formula.

Hi,

This is a little different compared to my earlier post.

Cell A1 has the value Qupcode
Cell B1 has the value ID
Cell B2 has the value 200034
Cell C2 has the value Fret

In Cell F2 I want to DISPLAY the value If ( ID = 200034 ) Qupcode = Fret
So, one can write the formula in Cell F2 as = "if ( " & B1 & " = " & B2 &
" ) " & A1 & " = " & C2

Now, Im writing this formula programmatically. So, I wrote the following
formula.

Cells(2, "f").Formula = "= ""if( "" & b1 & "" = """ & " & " & Cells(z,
"b").Address & " & "") "" & " & Cells(1, "a").Address & " & "" = "" & " &
Cells(z, "c").Address

If I go back to excel , it DISPLAYS the result as wanted.

Now, if I go in to editing mode then the formula is

= "if( " & B1 & " = " & $B$2 & ") " & $A$1 & " = " & $C$2

I have one requirement in the above. In the EDITING mode I prefer the actual
value in Cell(1,1) which is Qupcode rather than A1 or $A$1.

That is I want, the formula not to have any reference to Cell(1,1) but only
its value to be present.

How to accomplish the same programmatically?

Thanks a lot,
Hari
India


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
Formula to use date in file name link reference DFruge[_2_] Excel Worksheet Functions 2 May 23rd 09 02:12 AM
Add reference to DDE Link formula xlcharlie Excel Worksheet Functions 0 July 11th 06 05:03 PM
Using a cell reference as part of a link Missy Excel Discussion (Misc queries) 3 February 3rd 06 08:48 PM
Q: Can a formula reference a cell to get the file name to link to for data? mgarcia Excel Discussion (Misc queries) 3 January 18th 06 02:56 PM
Cell only shows link in text, not contents of reference cell Jay Mac New Users to Excel 4 August 23rd 05 08:36 PM


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