Cross Application Drag Drop
Posted: Tue Dec 18, 2012 10:19 pm
So I have a couple of questions regarding drag and drop. Specifically, I'm building a datagrid form with lines of data. Simple, basically just a field. I want to be able to drag a line from that field and drop it in a Word document (and, eventually, Pages, WordPerfect, etc--but first, just Word).
Now, I can drag and drop the text okay. But what I want to do is process said text (rather, format it) in Word once it is dropped. I want to mark it with a Word field code, to be exact. Can you create a piece of text that contains a Word field code in Livecode, which then would be able to be dropped into Word? I'm not sure the Pasteboard on the mac or whatever Windows uses can carry that cross applications, it's probably a Word only feature. So that means doing it via Applescript or VBA--after the drop happens.
So how can I know what application received my drop? Sending Applescript meant for Word to Pages is definitely a no-no.
Also, a completely unrelated question: Is it trivial to have a longish list of data somewhere and only show a subset of it in a datagrid, depending on various search filters? Like, I want to allow people to only show one category of the data, or to be able to filter it by name, and even to transform the data to "short" form versus a long form, depending on where they are dropping it into Word.
Thanks!
Now, I can drag and drop the text okay. But what I want to do is process said text (rather, format it) in Word once it is dropped. I want to mark it with a Word field code, to be exact. Can you create a piece of text that contains a Word field code in Livecode, which then would be able to be dropped into Word? I'm not sure the Pasteboard on the mac or whatever Windows uses can carry that cross applications, it's probably a Word only feature. So that means doing it via Applescript or VBA--after the drop happens.
So how can I know what application received my drop? Sending Applescript meant for Word to Pages is definitely a no-no.
Also, a completely unrelated question: Is it trivial to have a longish list of data somewhere and only show a subset of it in a datagrid, depending on various search filters? Like, I want to allow people to only show one category of the data, or to be able to filter it by name, and even to transform the data to "short" form versus a long form, depending on where they are dropping it into Word.
Thanks!