Results 1 to 3 of 3
  1. #1
    2 Star Lounger
    Join Date
    Jan 2001
    Location
    Melbourne, Victoria, Australia
    Posts
    199
    Thanks
    8
    Thanked 0 Times in 0 Posts

    Lotus Copy (Excel 2K)

    Hi,

    In Lotus123 there was a very useful facility whereby you could copy with the receiving cell as the active cell and then specify the Input range. This macro attempts to do this in Excel - but not very well.

    <pre>
    Sub Copy2()
    ' A Macro to copy from the destination range as per Lotus
    On Error GoTo EndCopy2
    Set ToCell = ActiveCell
    Set FromCell = Application.InputBox( _
    Prompt:="Select a cell(s) to copy", _
    Type:=8)
    ' If FromCell <> "" Then
    FromCell.Copy (ToCell)
    ' End If
    EndCopy2:
    End Sub
    </pre>


    It does not seem to do anything when a hidden cell is included in the range and does not copy ranges very happily.


    Any suggestions to make it more flexible and closer to the standard copy/paste facility?

    Thanks in Advance,

    Peter Moran
    Two heads are always better than one!!

  2. #2
    5 Star Lounger
    Join Date
    Oct 2002
    Location
    Wellington, Wellington, New Zealand
    Posts
    621
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Lotus Copy (Excel 2K)

    Peter
    I'm superstitious enough to select the cells in this case <img src=/S/grin.gif border=0 alt=grin width=15 height=15>
    The following worked for me:-

    Sub Copy2()
    Dim ToCell As Range, FromCell As Range
    ' A Macro to copy from the destination range as per Lotus
    'On Error GoTo EndCopy2
    Set ToCell = ActiveCell
    Set FromCell = Application.InputBox(Prompt:="Select a cell(s) to copy", Type:=8)
    ' If FromCell <> "" Then
    FromCell.Select
    Selection.Copy
    ToCell.Select
    ActiveSheet.Paste
    Application.CutCopyMode = False
    ' End If
    EndCopy2:

    End Sub

  3. #3
    2 Star Lounger
    Join Date
    Jan 2001
    Location
    Melbourne, Victoria, Australia
    Posts
    199
    Thanks
    8
    Thanked 0 Times in 0 Posts

    Re: Lotus Copy (Excel 2K)

    Hi Andrew,

    Thanks for the revision - it now seems to work the way it should!

    Sorry to see NZ beaten by Sri Lanka!

    Regards,

    Peter Moran
    Two heads are always better than one!!

Posting Permissions

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