Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
OLE linking creating large memo files.
Message
 
À
26/09/1999 10:43:20
Information générale
Forum:
Visual FoxPro
Catégorie:
Contrôles ActiveX en VFP
Divers
Thread ID:
00268920
Message ID:
00269225
Vues:
20
>Thanks very much for your reply Craig, but I think there is a more basic problem. Packing the memo file after you've inserted a picture does help.
>
>But... lets take the example of adding one 470KB paintbrush bitmap.
> I create a single dbf with a general field.
> My existing FTP file sits at 5KB before I link the picture.
>
> If I embed the bmp the file sizes jumps to 475 KB just like you'd expect.
> However if I LINK it the size increases to 2845 KB
> Performing a pack MEMO reduces it to 952 KB
>
>However that's still twice the size of the actual file. (1MB for a link!)
>This is nonsense, it would use less space if I embedded it.
>
>On the face of it this is such a common application (and so simple) I feel I must be doing something wrong. But after many hours of searching I still can't see what.(If it's relevant my 'blocksize' is the default 32)
>
>Thanks again, regards Mark.


Mark,

When you attach an OLE link to the file, the field still contains a picture of the contents for display (that's how you can view the field on a machine that doesn't have the application installed - you'll only get an error about not having the application if you attempt to edit it).

If I remember correctly, this rendering is usually in WMF format, which may be larger than .BMP (or whatever) plus there is some control information (I think you also get a rendering of the ICON): you will often get a smaller file-size if you embed rather than link, or use BINARY MEMO.

If you are going to link, use Craig's suggestion, just store the file-name. If you are going to embed, store in a memo.

If you must link because you want to display the file, you can always store in a memo, save to disk and create the link (to a scrap-file) when you display a form: be warned though, it takes time and if the user hasn't got the application installed you'll probably get an error.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform