Naomi,
if I use general fields and olebound control it will work for all with a ole handler. I can display it on my form. The problem is that I do not store the files as general for the common reasons. But I would like to display the files in the same way.
ShellExecute will runnot show the file on my form.
Agnes
>>>Hi,
>>>
>>>I have the following problem:
>>>
>>>I store a filename in an memo. This could be a file of any type, just as the user wishes.
>>>
>>>Now the user wants me to give a preview of this file in VFP (if possible).
>>>
>>>What object should I use?
>>>
>>>Agnes
>>
>>Let's put it this way. Do you know of
any program that can do this? Show about any arbitrary file in a preview, I mean.
>>
>>I think that you basically have the following options, the most important of which have already been suggested:
>>
>>1. Use ShellExecute() or a wrapper. This will give you the greatest flexibility, but you won't have control over user actions once the external program is opened.
>>
>
>Can you open file readonly using this method or you should change file attributes back and forth?
>
>
>>2. Use the Web browser control, to open many different file types.
>>
>>3. Continue searching for other controls, that offer you more options.
>>
>>4. Possibly use a combination of controls - e.g., if you detect a Word or Excel document, dynamically activate a control specifically designed for that file type.
Words are given to man to enable him to conceal his true feelings.
Charles Maurice de Talleyrand-Périgord
Weeks of programming can save you hours of planning.
OffThere is no place like [::1]