ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Invoking a workbook from a Fortran Program! (https://www.excelbanter.com/excel-programming/308722-invoking-workbook-fortran-program.html)

aiyer[_60_]

Invoking a workbook from a Fortran Program!
 
Hello all!

A quick question.
I have a workbook (Vtec.xls) that has macro buttons and custom create
menus and stuff performing different tasks.
I would like to invoke/call 'vtec.xls' from a Fortran code.
Is there any way we could do this?
Any alternatives?

I would really appreciate any help in this matter.

Thanks a bunch.

regds,
Arun.

Vt Corp

--
Message posted from http://www.ExcelForum.com


...Patrick[_5_]

Invoking a workbook from a Fortran Program!
 
Hello,
for me (i m not specialist) it is possible to read in your sheet xl, but not
write...
I have a problem with Reflection to readin xl and this is the superbe
reponse from Bill Manville:

I don't know anything about Reflection, but I would try using
automation. Create a Reference from your Reflection's VBproject to
Microsoft Excel N Object Library.

Dim oXL As Excel.Application
Dim V
Dim I As Integer
Set oXL = New Excel.Application
oXL.Workbooks.Open "C:\Mybook.xls"
For I=1 To 50
V = oXL.Sheets("Sheet1").Cells(I, 1).Value
' do what you will with that value V in Reflection
Next
oXL.ActiveWorkbook.Close False
oXL.Quit
Set oXL = Nothing

If you can deal with the data being in an array you could replace the
For loop with
V = oXL.Sheets("Sheet1").Range("A1:A50").Value

Bill Manville
MVP - Microsoft Excel, Oxford, England
No email replies please - respond to newsgroup



"aiyer " a écrit dans le message de
...
Hello all!

A quick question.
I have a workbook (Vtec.xls) that has macro buttons and custom created
menus and stuff performing different tasks.
I would like to invoke/call 'vtec.xls' from a Fortran code.
Is there any way we could do this?
Any alternatives?

I would really appreciate any help in this matter.

Thanks a bunch.

regds,
Arun.

Vt Corp.


---
Message posted from http://www.ExcelForum.com/





All times are GMT +1. The time now is 10:02 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com