Thanks Garrett,
This sounds like a good idea. I've never actually written a COM DLL, and find the documentation a little sketchy about the HOW. Do you have any suggestions for a good source of COM DLL examples that I could use to learn this from?
Andrew
>>Is it possible to use VFP 7 from within Excel without actually installing VFP on the target machine?
>>
>>I'm using syntax similar to the following:
>>
>>Dim oFox As Object
>>Set oFox = CreateObject("VisualFoxPro.Application")
>>
>>oFox.DoCmd "SELECT line_no,b_l,gl,units,shipper as shipcode,pro_no,corp,name as carrier,batch_no as batch ,line_no as Line, " + _
>> " (Fas_val+ex_value+fuel_app+insur_app+gst_app)" _
>> + " as Amount,gst_app as gst,weight as actual_wt, bweight as billed_wt, bill_date, supplier as customer, locname as destcity, " _
>> + "supplier.prov as destprov " _
>> + " from &mfile bills,&supFile supplier,f:\test\carrier carrier where batch_no = " + Workbooks("personalmacros.xls").Worksheets("sheet1").Range("c7") + _
>> " and consignee = supplier.code and carrier = carrier.code order " + _
>> "by name,batch_no,line_no into cursor batch1 "
>
>Have you tried to write a COM DLL with a DoCmd method which macro-substituted the parameter? It might be this easy.
>
>If it isn't, how about writing different methods such as DoSelect which have the command name in the method, with all the clauses added on with macros?
On a CLEAR day you can see forever.