Macros

P

pignataro1

I am brand new to Macro writing and I' m currently stumped! Trying to
write a Macro that I can use anywhere in a workbook on new or exisitng
sheets.

Attempting to copy a series of formulas (2 rows 25 columns across-
example formula ='RussoDI'!H15) down 2 rows, paste it and change only
the far right letter (H to G which refers to another sheets column).
I would also like to NOT change the cell but when copying, if I
started with H15 it automatically changes to H17. Is there anyway to
write a Macro that copies this range changes only the column letter,
and keep the actual cell #?

Thank you for any insight
 
J

Joel

Use the dollar sign to fix columns and row like you would on a worksheet.
Maybe you need to fix the worksheet and add the dolar signs.
 
P

pignataro1

Use the dollar sign to fix columns and row like you would on a worksheet.
Maybe you need to fix the worksheet and add the dolar signs.







- Show quoted text -

Thanks Joel-but you lost me. Remember that a couple of days ago, if
you mentioned Macro, I would think of the pasta dish that I was eating
for dinner that evening! Where should I insert $ signs-in the formula
on the sheet that I am working on?
 
J

Joel

You can havve 4 difffernt way to address a worksheet cell in a formula. The
formula can either be on the worksheet or in VBA
1) A1
2) $A1
3) A$1
4) $A$1

The dollar sign indicates when you copy the formula the row or column
doesn't change when you perform a copy.
 
P

pignataro1

You can havve 4 difffernt way to address a worksheet cell in a formula. The
formula can either be on the worksheet or in VBA
1) A1
2) $A1
3) A$1
4) $A$1

The dollar sign indicates when you copy the formula the row or column
doesn't change when you perform a copy.






- Show quoted text -

Great-is there a way to set that up to automatically (meaning have the
$ sign) appear when writing formula?

Also, how would I change only the column to go back one column
(example from H to G or better yet go forward to J or K) is there a
command to "go all the way to the right of the text string and find
the first capital letter and change that to G or whatever letter I
want? WIth this, I need to still leave the cell # the same-15 for
example

Thanks
 
J

JLGWhiz

What you need to do is click on Excel Help from the menu and type the
following into the search box:

About cell and range references

Click on the blue titles to open the dialog and it will explain what you are
asking.
 

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