zuladabef Posted January 28, 2019 Posted January 28, 2019 Hello, I am trying to parse data from clipboard. Somehow Windows knows that if I paste tabular data into an Excel file, that that data is tabular in someway. Can you help me understand how this works? I've looked through _ClipBoard_GetData and the MSDN a bit, but I'm not seeing anything that refers to tables. Is it using something like @TAB to paste tabular data? Thanks!
Danp2 Posted January 28, 2019 Posted January 28, 2019 Have you looked at the examples in the help file for functions like _ClipBoard_IsFormatAvailable and _ClipBoard_EnumFormats? Latest Webdriver UDF Release Webdriver Wiki FAQs
Subz Posted January 28, 2019 Posted January 28, 2019 It is pasting as a string and using @Tab. You could check if the ClipGet() has a tab in it, or multiple tabs example: ClipPut(1 & @TAB & 2 & @TAB & 3 & @TAB & 4) Local $aTabData = StringSplit(ClipGet(), @TAB) If $aTabData[0] >= 2 Then MsgBox(4096, "", ClipGet() & @CRLF & "No. of Tabs: " & ($aTabData[0] - 1)) Else MsgBox(4096, "", "No Tabs found") Endif
zuladabef Posted January 29, 2019 Author Posted January 29, 2019 16 hours ago, Danp2 said: Have you looked at the examples in the help file for functions like _ClipBoard_IsFormatAvailable and _ClipBoard_EnumFormats? I have, but I am not seeing how to determine the available formats? How does the MSDN view a Table?
zuladabef Posted January 31, 2019 Author Posted January 31, 2019 I am still stuck on this. _ClipBoard_EnumFormats outputs this: Clipboard formats ..: 9 Clipboard format 1 .: DataObject Clipboard format 2 .: Text Clipboard format 3 .: Unicode Text Clipboard format 4 .: HTML Format Clipboard format 5 .: Rich Text Format Clipboard format 6 .: msSourceUrl Clipboard format 7 .: Ole Private Data Clipboard format 8 .: Locale Clipboard format 9 .: OEM Text But, I don't know what to do with this. Which of these is the table? How do I isolate the data to only the table? Thanks for your help.
zuladabef Posted February 6, 2019 Author Posted February 6, 2019 Can anybody shed some light on this?
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now