Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

pasting from excel -- supported formats?

Status
Not open for further replies.

elf23

Programmer
Joined
Aug 13, 2003
Messages
1
Location
US
I am trying to implement a Paste function that will read data from excel and paste it to another spread sheet type container. I don't need detailed data for this program; the CF_TEXT format would suit my needs fine. However, when using IsDataAvailable(CF_TEXT), this returns TRUE whether there is data there or not. I would like to be able to verify that excel has put data on the clipboard before trying to process the data.

I have registered and tried to get "XlTable" format data from the clipboard, but IsDataAvailable returns false when passing this format as a parameter -- even when I have just used excel to copy to the clipboard. Can anyone give me some idea as to a format that excel uses to put data to the clipboard? This would be greatly appreciated.

 
you can paste such text as:
L"val A1\tval B1\tval C1\nval A2\tval B2\tval C2\nval A3\tval B3\tval C3"

\n means another row, and \t means an other cell. Above are persent three rows and three columns.

Ion Filipski
1c.bmp

ICQ: 95034075
AIM: IonFilipski
filipski@excite.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top