View Single Post
  #15   Report Post  
Posted to microsoft.public.excel.programming
Peter T[_8_] Peter T[_8_] is offline
external usenet poster
 
Posts: 88
Default Getting a variable's contents onto the clipboard

"Terry Pinnell" wrote in message
Thanks, but as mentioned in my later posts in that thread I now have it
working.
With code that at a glance looks very similar to yours above.

My original question was seeking expert advice/insights/confirmation on
points such
as
"...seems astonishingly complex."
"...seems rather inflexible too."
and particularly any better/simpler methods

Terry, East Grinstead, UK


API approaches can seem complex particularly if new to using APIs, and this
example perhaps more than most because different things are going on as part
of the whole operation. I guess your choice is just use it as offered or if
interested research how APIs work in general and these in particular.

However not sure why you describe it as inflexible. Quite the reverse, it's
far more flexible than say using the DataObject which is limited to text
only. With the APIs you can work with anything the clipboard can accept, and
retrieve information about the 'type' of data that's in the clipboard before
deciding to 'get' it. That said you would need to adapt the examples for use
with other data types.

As for any better methods - not really / simpler - indeed use the
DataObject!

Peter T