<I like a variation of the last one.>
OK!
I'm not sure I can oversee all the implications, like opening in a version of Excel with other list separators, R1C1 reference
style, etc. As long as they're recognized as formulas, that will be taken care of automatically, but with text, no. I even don't
know what happens in another language version. I do with worksheets, but I don't with worksheets copied from an add-in.
--
Kind regards,
Niek Otten
Microsoft MVP - Excel
|I like a variation of the last one.
|
| <bg>
|
| Niek Otten wrote:
| >
| > I hope someone more knowledgeable will answer, but it does indeed look like "looking back" to the add-in.
| > If that is the case, you might try using a cell with the worksheet name and use the INDIRECT() function in the formula.
| > Or use formulas without an equals-sign, and add that after copying and pasting, but I don't feel very comfortable with that
last
| > solution.
| >
| > --
| > Kind regards,
| >
| > Niek Otten
| > Microsoft MVP - Excel
| >
| > | The existing workbook contains two sheets Sabourin and Jagiello. The
| > | addin file contains a sheet called What If. The addin file contains
| > | formulas that directly refrence the data in "Jagiello". Here is the
| > | code that I use to copy the addin to the existing workbook:
| > |
| > | Sub Auto_Open()
| > | ThisWorkbook.Sheets("What If").Copy
| > | after:=ActiveWorkbook.Sheets("jagiello")
| > | End Sub
| > |
| > | This process works fine. It is when the sheet copies I can't get it to
| > | refrence the sheet "Jagiello". It appears to be trying to lookback at
| > | the addin file. Here is a sample of one of my folmulas.
| > |
| > |
| >
=IF($A$6=Jagiello!$A$10,Jagiello!C10,IF($A$6=Jagiello!$A$9,Jagiello!C9,IF($A$6=Jagiello!$A$8,Jagiello!C8,IF($A$6=Jagiello!$A$7,Jagiello!C7,IF($A$6=Jagiello!$A$6,Jagiello!C6,0)))))
| > |
| > | #REF pops up in place of Jagiello!(cell#)
| > |
| > | Let me know if you need anything else.
| > |
| > | PS Sorry about the double post.
| > |
| > | > Post your code and the type of formulas.
| > | >
| > | > --
| > | > Kind regards,
| > | >
| > | > Niek Otten
| > | > Microsoft MVP - Excel
| > | >
| > creating and addin that when opened will copy itself into an
| > | > | existing workbook. From there the copied worksheet is supposed to pull
| > | > | data from another worksheet and allow the user to manipulate it. I
| > | > | created the worksheet in the same workbook that it will be used in.
| > | > | Made sure all the formulas worked as desired and that everything was
| > | > | the way i wanted it to be. However, when I copy the addin worksheet to
| > | > | a new workbook to actually make it an addin I loose all my references.
| > | > | How do I change the formulas so that when the worksheet is copied into
| > | > | the existing workbook it references the cells properly.
| > | > |
| > |
|
| --
|
| Dave Peterson