Re: Change file reference on OLE object
- From: "Gregory Adam" <GregoryAdam@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Thu, 17 Aug 2006 19:06:53 +0200
Cathy,
Not tested. Digging up old code
If (1) doesn't do the job, try (2)
(1)
=obj.workbooks(1).SaveAs(NewDocumentPath)
(2)
=obj.workbooks(1).SaveAs(NewDocumentPath)
=obj.workbooks(1).Close()
=obj.workbooks.Open(NewDocumentPath)
Gregory
__________
"Cathy Neppel" <Cathy Neppel@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message news:F9D1959E-7FAD-486C-9107-0604C2F67C06@xxxxxxxxxxxxxxxx
Hi,
I have an Excel file that I'm displaying in a VFP form using an OLE control,
linking it to a local file.
Problem is, sometimes that local file gets locked up, and I can't overwrite
it with new data in order to display it in my form. Either the user has it
open in Excel, or in some cases, just having Excel open locks it up (can't
figure that one out...)
I would like to be able to dynamically change the file name that I'm
displaying, so that I can control it from within the program and not have it
hard-coded. But the OLE control's DocumentFile property is read-only at run
time.
Any ideas on this? Am I using the control wrong, or the wrong control?
Thanks,
Cathy
.
- Prev by Date: Re: [MSDE] What is the command to truncate the logs?
- Next by Date: Need Help with Search
- Previous by thread: Is it possible to use Foxpro forms as a backbone to generate PHP+MySQL+AJAX codes?
- Next by thread: Re: Change file reference on OLE object
- Index(es):
Relevant Pages
|