ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   formual to get reference contents (https://www.excelbanter.com/excel-discussion-misc-queries/129325-formual-get-reference-contents.html)

John M

formual to get reference contents
 
Hi,
How can i get the reference contents from a cell? This may be explained
with an example. Cell contains "Sheet1!A5" which equates to 20 say. If i
use cell function i can only get 20. How can i extract the "Sheet1!A5"
information.

Thanks in advance

Michael

formual to get reference contents
 
One way is to select Tools -- Options, and on the View tab, check Formulas.
Your spreadsheet will now show formulas, not results. Print it and then
deselect formulas on the View Tab. HTH
Sincerely, Michael Colvin


"John M" wrote:

Hi,
How can i get the reference contents from a cell? This may be explained
with an example. Cell contains "Sheet1!A5" which equates to 20 say. If i
use cell function i can only get 20. How can i extract the "Sheet1!A5"
information.

Thanks in advance


John M

formual to get reference contents
 
Michael,

I want to get it from a formula and not just to view them.

Thanks anyway.

"Michael" wrote:

One way is to select Tools -- Options, and on the View tab, check Formulas.
Your spreadsheet will now show formulas, not results. Print it and then
deselect formulas on the View Tab. HTH
Sincerely, Michael Colvin


"John M" wrote:

Hi,
How can i get the reference contents from a cell? This may be explained
with an example. Cell contains "Sheet1!A5" which equates to 20 say. If i
use cell function i can only get 20. How can i extract the "Sheet1!A5"
information.

Thanks in advance


pinmaster

formual to get reference contents
 
Hi John

I've seen a similar request not too long ago. Someone had an answer using a
UDF. A search might come up with something.

Regards!
Jean-Guy

"John M" wrote:

Michael,

I want to get it from a formula and not just to view them.

Thanks anyway.

"Michael" wrote:

One way is to select Tools -- Options, and on the View tab, check Formulas.
Your spreadsheet will now show formulas, not results. Print it and then
deselect formulas on the View Tab. HTH
Sincerely, Michael Colvin


"John M" wrote:

Hi,
How can i get the reference contents from a cell? This may be explained
with an example. Cell contains "Sheet1!A5" which equates to 20 say. If i
use cell function i can only get 20. How can i extract the "Sheet1!A5"
information.

Thanks in advance


Ron Rosenfeld

formual to get reference contents
 
On Mon, 5 Feb 2007 12:31:00 -0800, John M
wrote:

Hi,
How can i get the reference contents from a cell? This may be explained
with an example. Cell contains "Sheet1!A5" which equates to 20 say. If i
use cell function i can only get 20. How can i extract the "Sheet1!A5"
information.

Thanks in advance


You will need a UDF in VB.

<alt-F11 opens the VB Editor
Ensure your project is highlighted in the Project Explorer window, then
Insert/Module and paste the code below into the window that opens.

To use this UDF, enter the formula

=ShowFormula(cell_ref) into some cell. It will display the actual contents of
cell_ref

=============================================
Function ShowFormula(rg As Range) As String
ShowFormula = rg.Formula
End Function
=============================================


--ron


All times are GMT +1. The time now is 05:38 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com