VBA, get the range marked to copy (or cut)
When user select and mark range to cut/copy, in VBA exists Application.CutCopyMode to check if there are some range to cut/copy. But I need some property that return this range (Application.CutCopyRange)
Robert Goff commented
I was just doing some research on this subject. The DataObject class (<https://msdn.microsoft.com/en-us/library/system.windows.forms.dataobject(v=vs.110).aspx>) has methods to retrieve all of the data formats on the system clipboard; unfortunately, the interface exposed to VBA in "Microsoft Forms 2.0 Object Library" only supports text.
If you use a clipboard viewer (like <http://www.freeclipboardviewer.com/>) you can prove to yourself that the data placed on the clipboard by Excel contains the address of the range in at least one format ("OwnerLink") and possibly more. When I have more time I'll try to import a Windows API function to access the object.
Maybe creating a new property in vba (such as Application.CutCopyRange) requires to wait for a new vba release, which will certainly oblige us to wait until the next office 2019.
*** SUGGESTION **
Create a new system defined named range which will contain the range address of the last copied cells. We already have some system defined ranges, such as the print_area and even some others which are hidden by default. this will NOT require any vba upgrade and seem easy to implement.
Range name suggestion: "_CopiedRange", or "_CutRange" (hidden by default)
Every time we would make a copy (or Cut) of a range, the named range would be automatically updated, and would be easilly accessible by vba.
Now that MS has update the Cut/Copy system, making Excel to remember (longer) the copied Range (keeping the marching ants running), please "push-it a bit further" and give us a most needed easy way to get the copied (or Cut) range from vba.
Application.CutCopyRange is a good suggestion.