+ Reply to Thread
Results 1 to 3 of 3

Quick method to add absolute references in Excel using keyboard

  1. #1
    photon63
    Guest

    Quick method to add absolute references in Excel using keyboard

    It would be useful for absolute references to be added in Excel when holding
    a key down on the keyboard, instead of having to re-edit each cell every
    time. Say, hold down the mouse button, press 'r' to toggle rows between
    absolute and relative, and the same for 'c' and columns.

  2. #2
    Smuggy
    Guest

    RE: Quick method to add absolute references in Excel using keyboard

    Here's an excellent routine for you, gives you two subroutines Reltoabs and
    Abstorel which you could then assign to keyboard shortcut or to an icon on
    toolbar...

    Sub ReltoAbs()
    Dim Cell As Range
    For Each Cell In Selection
    Cell.Formula = Application.ConvertFormula(Cell.Formula, xlA1, xlA1,
    xlAbsolute)
    Next
    End Sub

    Sub AbstoRel()
    Dim Cell As Range
    For Each Cell In Selection
    Cell.Formula = Application.ConvertFormula(Cell.Formula, xlA1, xlA1,
    xlRelative)
    Next
    End Sub

    Sub RelColAbsRows()
    Dim Cell As Range
    For Each Cell In Selection
    Cell.Formula = Application.ConvertFormula(Cell.Formula, xlA1, xlA1,
    xlAbsRowRelColumn)
    Next
    End Sub

    Sub RelRowsAbsCol()
    Dim Cell As Range
    For Each Cell In Selection
    Cell.Formula = Application.ConvertFormula(Cell.Formula, xlA1, xlA1,
    xlRelRowAbsColumn)
    Next
    End Sub


    Steve
    PS. I wish I could claim the credit for this, but I can't - thought I would
    post it for you anyway.




    "photon63" wrote:

    > It would be useful for absolute references to be added in Excel when holding
    > a key down on the keyboard, instead of having to re-edit each cell every
    > time. Say, hold down the mouse button, press 'r' to toggle rows between
    > absolute and relative, and the same for 'c' and columns.


  3. #3
    photon63
    Guest

    RE: Quick method to add absolute references in Excel using keyboar

    Thanks - much appreciated

    "Smuggy" wrote:

    > Here's an excellent routine for you, gives you two subroutines Reltoabs and
    > Abstorel which you could then assign to keyboard shortcut or to an icon on
    > toolbar...
    >
    > Sub ReltoAbs()
    > Dim Cell As Range
    > For Each Cell In Selection
    > Cell.Formula = Application.ConvertFormula(Cell.Formula, xlA1, xlA1,
    > xlAbsolute)
    > Next
    > End Sub
    >
    > Sub AbstoRel()
    > Dim Cell As Range
    > For Each Cell In Selection
    > Cell.Formula = Application.ConvertFormula(Cell.Formula, xlA1, xlA1,
    > xlRelative)
    > Next
    > End Sub
    >
    > Sub RelColAbsRows()
    > Dim Cell As Range
    > For Each Cell In Selection
    > Cell.Formula = Application.ConvertFormula(Cell.Formula, xlA1, xlA1,
    > xlAbsRowRelColumn)
    > Next
    > End Sub
    >
    > Sub RelRowsAbsCol()
    > Dim Cell As Range
    > For Each Cell In Selection
    > Cell.Formula = Application.ConvertFormula(Cell.Formula, xlA1, xlA1,
    > xlRelRowAbsColumn)
    > Next
    > End Sub
    >
    >
    > Steve
    > PS. I wish I could claim the credit for this, but I can't - thought I would
    > post it for you anyway.
    >
    >
    >
    >
    > "photon63" wrote:
    >
    > > It would be useful for absolute references to be added in Excel when holding
    > > a key down on the keyboard, instead of having to re-edit each cell every
    > > time. Say, hold down the mouse button, press 'r' to toggle rows between
    > > absolute and relative, and the same for 'c' and columns.


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1