Hi Nicola (NWT) The code is working fine on my system. But we use . (dot,period,full stop) as decimal separator instead of , (comma) for decimal/double/ real numbers. I don't know about italian system but think programming practices are followed same throughout the world. So kindly replace , with . and see, if it's helpful and works for you too.
For more tips, tricks, downloads and problem solutions: visit --> http://www.excelitems.com ------------------------------------------------------------------------ Regards Ashish Jain Analyst and Demand-Co-ordinator, CSC Australia Microsoft Certified Application (Excel) Specialist Technical Trainer - Excel and VBA Author -> www.excelitems.com 09999-40-48-43 ---------------------------------------------------------------------------------------------------------------------------- ---------------------------------------------------------------------------------------------------------------------------- On Mar 2, 1:13 am, Nwt <nicola.fe...@gmail.com> wrote: Hi all, i'm trying to insert a formula by vba, the code looks like this: dbl_weight = 27,7 activecell.FormulaR1C1 = "=RC[-6]*" & dbl_weight runtime error 1004 if my dbl_weight = 27 it works my excel 2003 is in italian any suggestion? Thanks, Nwt --~--~---------~--~----~------------~-------~--~----~ ------------------------------------------------------------------------------------- Some important links for excel users: 1. Excel and VBA Tutorials(Video and Text), Free add-ins downloads at http://www.excelitems.com 2. Excel tutorials at http://www.excel-macros.blogspot.com 3. Learn VBA Macros at http://www.vbamacros.blogspot.com 4. Excel Tips and Tricks at http://exceldailytip.blogspot.com To post to this group, send email to excel-macros@googlegroups.com If you find any spam message in the group, please send an email to: Ayush Jain @ jainayus...@gmail.com or Ashish Jain @ 26may.1...@gmail.com ------------------------------------------------------------------------------------- -~----------~----~----~----~------~----~------~--~---