Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Copying controls _clipWhat
Message
From
01/03/2013 07:51:15
 
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Environment versions
Visual FoxPro:
VFP 9 SP1
Miscellaneous
Thread ID:
01567008
Message ID:
01567236
Views:
119
>>>We have ASelObj when modifying forms or classes. This allows us to know the currently selected object (or objects), from which we can learn the PEMs and their values, sibling objects, child objects, and the top-level object being edited, and other functions and methods allows us to create PEMs, and remove child objects, etc.. All of PEM Editor depends on this.
>>>
>>>I have never heard of any similar feature when using the Report Designer. Without it, I think this suggestion can go nowhere.
>>
>>I know that there is no aselobj() in RD. However when you select multiple report textboxes for instance, VFP/RD knows which are those.
>>There is some clipboard info filled in somewhere (where ??) which is then used by VFP/RD to copy them. Content of that clipboard (where ever it is kept) is what I am after. Any ideas how this info can be retrieved ?
>
>
>It is not hopeless, do not listen to Jim! :)
>
>
>Actually it seems pretty easy, when you copy from the report writer into the clipboard Foxpro creates a report in the tmpfiles folder (extension tmp, but it is a report table), so you just can use that file as a table and do a translation to scx format for all the records in there. Now the trick is to get the name of the file, and it is a long time since I last played with the clipboard, but the name of the file is in there with format 49643, so you should be able to use GetClipboardData() and retrieve this name, to see what I am talking about, download a clipboard viewer (I just googled and found this one http://www.nirsoft.net/utils/inside_clipboard.html) and you can see there the name of the file created with a record for each object you selected and copied in your report.
>
>{Update} The same applies to a form with format id 49641, and this time even the extension is scx{/update}


Hi Hugo :)

This is great tip! Exactly what I hoped I would find !
And it is perfectly logical from VFP code standpoint. Copying controls in RD / FD is just copying records (FRX/SCX respectively)
so they did what anybody practical would do; Dump those records into temp dbf and then copy from there.

For my local use only I can probably do away just by retrieving whatever scx/frx data are in that temp folder and then
using them in my own form builder class to create that frx content as form controls. What I described as ideal scenario earlier
(making it work both ways and be part of something like Thor) is probably much much more work.

But hey this is a great start !

Thks+++ Everybody
*****************
Srdjan Djordjevic
Limassol, Cyprus

Free Reporting Framework for VFP9 ;
www.Report-Sculptor.Com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform