PC Review


Reply
Thread Tools Rate Thread

Copy Workbook, Formula Not Working

 
 
=?Utf-8?B?Q2hhcmxpZQ==?=
Guest
Posts: n/a
 
      2nd Oct 2007
Hi,

I have a workbook that uses a macro function in a formula

=EditDescription(ROW(),Description)

"Description" is a local (sheet-level) named range down one column on
several sheets, "EditDescription" is a string function to remove LineFeeds,
etc.

It works fine when the workbook is generated on our server, but when I copy
it to my local workstation and open it the formulas don't work. Sheet1 is
OK. What I see on the other sheets is the same description from Sheet1. If
I click in the formula bar and press Enter the formula recalculates
correctly. It picks up the correct description from the named range on that
sheet. If I drag the formula down the column again they all recalculate
correctly.

I've tried using the .Calculate method, and recalculating the sheet from
Tools-->Options-->Calculation. The only thing that works is clicking in the
formula bar or dragging the formula down the column.

Anyone know why this is happening and how to fix it?

TIA
Charlie

 
Reply With Quote
 
 
 
 
=?Utf-8?B?VG9tIE9naWx2eQ==?=
Guest
Posts: n/a
 
      2nd Oct 2007
try changing the formula to

=EditDescription(ROW()+rand()*0,Description)

This should make it update on every recalculation.


--
Regards,
Tom Ogilvy


"Charlie" wrote:

> Hi,
>
> I have a workbook that uses a macro function in a formula
>
> =EditDescription(ROW(),Description)
>
> "Description" is a local (sheet-level) named range down one column on
> several sheets, "EditDescription" is a string function to remove LineFeeds,
> etc.
>
> It works fine when the workbook is generated on our server, but when I copy
> it to my local workstation and open it the formulas don't work. Sheet1 is
> OK. What I see on the other sheets is the same description from Sheet1. If
> I click in the formula bar and press Enter the formula recalculates
> correctly. It picks up the correct description from the named range on that
> sheet. If I drag the formula down the column again they all recalculate
> correctly.
>
> I've tried using the .Calculate method, and recalculating the sheet from
> Tools-->Options-->Calculation. The only thing that works is clicking in the
> formula bar or dragging the formula down the column.
>
> Anyone know why this is happening and how to fix it?
>
> TIA
> Charlie
>

 
Reply With Quote
 
=?Utf-8?B?Q2hhcmxpZQ==?=
Guest
Posts: n/a
 
      2nd Oct 2007
I tried your work-around but it actually had the opposite effect! Now the
workbook created on the server does not calculate Sheet2, although when I
clicked in the formula bar and pressed Enter it DID recalculate the whole
sheet instead of just the one cell.

We are using Citrix to run a remote app on a server. That app creates the
workbook and launches Excel to show it. The version of Excel on the server
is older than on my workstation (where I created the report template.) That
may be the problem. If my company won't upgrade the server version of Excel
I may have to rewrite the report template.

Thanks for the suggestion.

P.S. I checked the macro security option -- "Low" both places.


"Tom Ogilvy" wrote:

> try changing the formula to
>
> =EditDescription(ROW()+rand()*0,Description)
>
> This should make it update on every recalculation.
>
>
> --
> Regards,
> Tom Ogilvy
>
>
> "Charlie" wrote:
>
> > Hi,
> >
> > I have a workbook that uses a macro function in a formula
> >
> > =EditDescription(ROW(),Description)
> >
> > "Description" is a local (sheet-level) named range down one column on
> > several sheets, "EditDescription" is a string function to remove LineFeeds,
> > etc.
> >
> > It works fine when the workbook is generated on our server, but when I copy
> > it to my local workstation and open it the formulas don't work. Sheet1 is
> > OK. What I see on the other sheets is the same description from Sheet1. If
> > I click in the formula bar and press Enter the formula recalculates
> > correctly. It picks up the correct description from the named range on that
> > sheet. If I drag the formula down the column again they all recalculate
> > correctly.
> >
> > I've tried using the .Calculate method, and recalculating the sheet from
> > Tools-->Options-->Calculation. The only thing that works is clicking in the
> > formula bar or dragging the formula down the column.
> >
> > Anyone know why this is happening and how to fix it?
> >
> > TIA
> > Charlie
> >

 
Reply With Quote
 
=?Utf-8?B?VG9tIE9naWx2eQ==?=
Guest
Posts: n/a
 
      2nd Oct 2007
If it did recalculate the whole sheet and not just the one cell, then I
suspect it performed as I intended. I can't say what is going on when the
workbook is created. My intent was to make the function volatile since
Excel doesn't see the references in the argument list as needing to have the
formula recalculate.

--
Regards,
Tom Ogilvy




"Charlie" wrote:

> I tried your work-around but it actually had the opposite effect! Now the
> workbook created on the server does not calculate Sheet2, although when I
> clicked in the formula bar and pressed Enter it DID recalculate the whole
> sheet instead of just the one cell.
>
> We are using Citrix to run a remote app on a server. That app creates the
> workbook and launches Excel to show it. The version of Excel on the server
> is older than on my workstation (where I created the report template.) That
> may be the problem. If my company won't upgrade the server version of Excel
> I may have to rewrite the report template.
>
> Thanks for the suggestion.
>
> P.S. I checked the macro security option -- "Low" both places.
>
>
> "Tom Ogilvy" wrote:
>
> > try changing the formula to
> >
> > =EditDescription(ROW()+rand()*0,Description)
> >
> > This should make it update on every recalculation.
> >
> >
> > --
> > Regards,
> > Tom Ogilvy
> >
> >
> > "Charlie" wrote:
> >
> > > Hi,
> > >
> > > I have a workbook that uses a macro function in a formula
> > >
> > > =EditDescription(ROW(),Description)
> > >
> > > "Description" is a local (sheet-level) named range down one column on
> > > several sheets, "EditDescription" is a string function to remove LineFeeds,
> > > etc.
> > >
> > > It works fine when the workbook is generated on our server, but when I copy
> > > it to my local workstation and open it the formulas don't work. Sheet1 is
> > > OK. What I see on the other sheets is the same description from Sheet1. If
> > > I click in the formula bar and press Enter the formula recalculates
> > > correctly. It picks up the correct description from the named range on that
> > > sheet. If I drag the formula down the column again they all recalculate
> > > correctly.
> > >
> > > I've tried using the .Calculate method, and recalculating the sheet from
> > > Tools-->Options-->Calculation. The only thing that works is clicking in the
> > > formula bar or dragging the formula down the column.
> > >
> > > Anyone know why this is happening and how to fix it?
> > >
> > > TIA
> > > Charlie
> > >

 
Reply With Quote
 
=?Utf-8?B?Q2hhcmxpZQ==?=
Guest
Posts: n/a
 
      2nd Oct 2007
True, it did recalculate as you expected. The problem is something else.
(Not the different version problem either. Someone here has a copy of the
remote app on his local workstation, with the latest version of Excel, and we
still have the problem.)

I was able to make the sheets recalculate by looping through each sheet in
Workbook_Open and repasting the formula in the columns, but I'd like to know
why it doesn't work.

What it appears is that it's not necessarily Sheet1's data (from that
column) that appears on all other sheets, but rather whatever sheet was the
active sheet when the book was saved shows that calculated values on all the
other sheets.

I'm gonna keep pluggin away at it.

"Tom Ogilvy" wrote:

> If it did recalculate the whole sheet and not just the one cell, then I
> suspect it performed as I intended. I can't say what is going on when the
> workbook is created. My intent was to make the function volatile since
> Excel doesn't see the references in the argument list as needing to have the
> formula recalculate.
>
> --
> Regards,
> Tom Ogilvy
>
>
>
>
> "Charlie" wrote:
>
> > I tried your work-around but it actually had the opposite effect! Now the
> > workbook created on the server does not calculate Sheet2, although when I
> > clicked in the formula bar and pressed Enter it DID recalculate the whole
> > sheet instead of just the one cell.
> >
> > We are using Citrix to run a remote app on a server. That app creates the
> > workbook and launches Excel to show it. The version of Excel on the server
> > is older than on my workstation (where I created the report template.) That
> > may be the problem. If my company won't upgrade the server version of Excel
> > I may have to rewrite the report template.
> >
> > Thanks for the suggestion.
> >
> > P.S. I checked the macro security option -- "Low" both places.
> >
> >
> > "Tom Ogilvy" wrote:
> >
> > > try changing the formula to
> > >
> > > =EditDescription(ROW()+rand()*0,Description)
> > >
> > > This should make it update on every recalculation.
> > >
> > >
> > > --
> > > Regards,
> > > Tom Ogilvy
> > >
> > >
> > > "Charlie" wrote:
> > >
> > > > Hi,
> > > >
> > > > I have a workbook that uses a macro function in a formula
> > > >
> > > > =EditDescription(ROW(),Description)
> > > >
> > > > "Description" is a local (sheet-level) named range down one column on
> > > > several sheets, "EditDescription" is a string function to remove LineFeeds,
> > > > etc.
> > > >
> > > > It works fine when the workbook is generated on our server, but when I copy
> > > > it to my local workstation and open it the formulas don't work. Sheet1 is
> > > > OK. What I see on the other sheets is the same description from Sheet1. If
> > > > I click in the formula bar and press Enter the formula recalculates
> > > > correctly. It picks up the correct description from the named range on that
> > > > sheet. If I drag the formula down the column again they all recalculate
> > > > correctly.
> > > >
> > > > I've tried using the .Calculate method, and recalculating the sheet from
> > > > Tools-->Options-->Calculation. The only thing that works is clicking in the
> > > > formula bar or dragging the formula down the column.
> > > >
> > > > Anyone know why this is happening and how to fix it?
> > > >
> > > > TIA
> > > > Charlie
> > > >

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I copy formula from one workbook to another? =?Utf-8?B?ZHJyb2Jpbg==?= Microsoft Excel Misc 1 23rd Apr 2006 04:08 PM
how to copy formula from one workbook to another =?Utf-8?B?cHNw?= Microsoft Excel Misc 2 2nd Sep 2005 04:33 PM
Copy Formula to Different Workbook rookerr Microsoft Excel Worksheet Functions 1 24th Aug 2005 02:17 PM
COPY FORMULA FROM ONE WORKBOOK INTO ANOTHER WORKBOOK =?Utf-8?B?RUFSTF9JTl9NT0RFU1RPQE1TTi5DT00=?= Microsoft Excel New Users 2 10th Jul 2004 01:06 AM
How to copy formula to a different workbook so it uses the new workbook's data? Holly Balasubramanian Microsoft Excel Worksheet Functions 2 18th Jul 2003 02:58 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:05 PM.