recording macro to paste a copied ws formula

P

Peter

Hello everyone,

Using the macrorecorder to record the pasting of a copied worksheetformula
into a cell seems to cause a problem for a ws-formula that has, in this
case, 252 characters. (Dutch MS-Office-Excel 2003/XP Home Dutch)

Is there a way to have vba code insert such a long worksheetformula into a
cell?

For all intents and purposes I hereby give you the formula as is when the
worksheet containing it is opened in the English version of MS-Office-Excel
XP):

=IF(ISERROR(IF(LEFT(id_projectie;4)="oud:";0;ROUND(SUM(D3:OFFSET(INDIRECT(E1
9);0;-1))/MAX(E3:E14)*(12-MAX(E3:E14));2)));"";IF(LEFT(id_projectie;4)="oud:
";0;ROUND(SUM(D3:OFFSET(INDIRECT(E19);0;-1))/MAX(E3:E14)*(12-MAX(E3:E14));2)
))

The dutch words in this formula translate to:
IF > ALS
ISERROR > ISFOUT
LEFT > LINKS
ROUND > AFRONDEN
OFFSET > VERSCHUIVING

Thanks for your help

Peter
 
R

Ron de Bruin

Hi Peter

I don't see your code but if you use
activecell.Formula = ...........................

Then use a , instead of ; in the VBA code (VBA = US)
It will change it to ; when you open it in a Duch version
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top