- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have a VB6 project that is written to interact with Fortran and get the data back to the user. We opened up Fortran and through the wizard created the module containing the Automation interface of the objects. This process created a whole bunch of code in a .F90 file. This works fine and we get the desired results that we are looking for. However when i upgraded the code to VB.Net and tried to replicate the steps through Wizard we don't get the similar code that was generated for VB6. Infact a .F90 file is created with just about 6 lines of code and at the end of the code we see a line that says " ! No interfaces of the type requested were found". On the first screen of the wizard i check the box "Generate code that uses automation interface" and then i can choose any options on the second screen and get the same results all the time. Am i not following some steps or missing some steps? I am using Windows 7, VS 2008 and Studio XE 2013. Please let me know what i need to do as i have spent quite a bit of time trying to make this work.
SW
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
SW,
In your VB.NET project, have you made sure to do the following?
1) Register it for COM Interop? Remeber the Fortran module wizard allows Fortran to interact with COM applications, hence the .NET application must include interoperability with COM.
2) Follow the .NET requirements for COM interop? i.e., include interfaces for all the exported classes and their properties and methods. If not, you can refer to Microsoft Help in Visual Studio for details on the interfaces. If your .NET code will see future revisions and updates, it may be useful to specify explicit GUIDs (using the Guid attribute in your .NET code) for every item that is to be made visible to COM.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes i have done that, but for some reason the code that gets generated states "No interfaces of the type requested were found" and is recognising the .Net file as .TLB file. Is this normal. And the code that gets generated is very small compared to the one that is generated for VB file.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It appears something is amiss in your .NET assembly and/or the type library. I would suggest you first make sure everything is proper in your .NET project. You can use ILDASM and Object Browser tools provided by Microsoft to check things - refer to Microsoft documentation e.g., http://msdn.microsoft.com/en-us/library/98w057c3(v=vs.80).aspx.
I've successfully used the Intel module wizard, most recently with Intel Composer XE 2013, latest update.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am browsing to the .net application from fortran module wizard that i want to use. Once i select it the wizard shows me the correct path but once the wizard builds the interface in the code i see as comment "This module contains the COM interfaces of the objects defined in" and the path that it shows is absolute different from where i had pointed to in the wizard's browse for assembly box. Any ideas?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi
This is where i am pointing the wizard to pick my .exe from "C:\Users\SWILL10\Desktop\ForTran\Pro2_9.1 - v5\P2CCServer DLL - vb\P2CompassServer.NET1\bin\P2Spiral.exe"
And this is what the path is in the generated Fortran module
! This module contains the COM interfaces of the objects defined in
! C:\Users\SWILL10\AppData\Local\Temp\P2SpiralServer.TLB
! Generated by the Fortran Module Wizard on 05/14/13
SW
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
SW,
From what I have gathered, the module wizard generally wants to work off of the type library (TLB file); if you point directly to a .NET DLL or EXE file instead, my understanding is that it creates a type library behind the scenes using some utility in Visual Studio - I could be wrong, but that's what I see on my PC (someone from Intel may be able to shed more light on this). So, based on my understanding, what you see with paths is not really an issue. The path inside the Fortran module seems to just a temporary folder where the TLB got created.
Now what you may want to do is check for a TLB file in your project folder and its sub-folders: C:\Users\SWILL10\Desktop\ForTran\Pro2_9.1 - v5\P2CCServer DLL - vb\P2CompassServer.NET1". If you did all the COM interoperability things correctly in your .NET project as you say, then Visual Studio should have created a TLB file for you in one of your subfolders in this project. I got the TLB file automatically once I added all the COM interop stuff.
If you find TLB, use the Visual Studio "View Object Browser" tool (refer to Microsoft documentation as I indicated above) to look at the "exposed" content for COM interop i.e., the classes, their methods and properties, etc that you want to invoke in any COM application (including Fortran). If what you need in Fortran in missing here, then you need to modify your .NET code until everything is visible and the attributes are correct.
Only after you are satisfied with you see in the TLB should you try to run the Intel module wizard.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
OK Now i am getting a new error "fatal error LNK1104: cannot open file 'ifconsol.lib'". when trying to build the solution. I am using VS 2008 and fortran 11. We have a VB 6.0 code that we linked in this project through Visual fortran wizard. Can you please help me resolve this issue. Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Please set the linker project property General > Show Progress to "Show some progress messages" , do a rebuild, and then attach a ZIP of the buildlog.htm to a reply here.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Steve i am very new to frtran so you will have to really spell it out for me how to set "Show some progress messages". This program was built by someone else and i am just trying to maintain it. Below is the the buildlog.htm to this message of whatever got built. Maybe i can do it again if this is not full compile log that you were expecting.
Build started: Project: Testmain, Configuration: Debug|Win32 Output Linking... Link /OUT:"Debug/Testmain.exe" /INCREMENTAL:NO /NOLOGO /MANIFEST /MANIFESTFILE:"C:\Users\SWILL10\Desktop\LatestWorkingCopies\ASIDLL - Fortran\Debug\Testmain.exe.intermediate.manifest" /MANIFESTUAC:"level='asInvoker' uiAccess='false'" /DEBUG /PDB:"Debug/Testmain.pdb" /SUBSYSTEM:CONSOLE kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /MACHINE:I386 "Debug/TestMain.obj" "Debug/P2SpiralServer.obj" "Debug/P2CCServer.obj" "Debug/CRDIDL.obj" "Debug/XMCrudeListSize.obj" "Debug/CRDCMP.obj" "Debug/XMCrudeIDs.obj" "c:\Users\SWILL10\Desktop\LatestWorkingCopies\ASIDLL - Fortran\Debug\Testmain_lib.lib" Link: executing 'link' Testmain_lib.lib(XMCrudeList.obj) : warning LNK4075: ignoring '/EDITANDCONTINUE' due to '/INCREMENTAL:NO' specification LINK : fatal error LNK1104: cannot open file 'ifconsol.lib' Testmain - 1 error(s), 1 warning(s)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Right click on the Fortran project (not the solution - the icon with the F) and select Properties. In the left column, under Configuration Properties, select Linker > General. Change the entry for "Show Progress" to "Display All Progress Messages", click OK.
Now do a full rebuild (not just a build like you did above) of the solution.
In the Debug subfolder of the project is a file buildlog.htm. Zip that and attach it to a reply here.
Also, please do this. In Visual Studio, select Tools > Options > Intel Fortran Composer XE > Visual Fortran > Compilers. You will see an entry that says Libraries. Click the ... button to the right of that, copy all the text in the window that appears and paste it into your reply.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Steve When i click for propperties nothing happens and i don't see any configuration properties. Also in VS under tools>options I don't see Intel Fortran Composer XE. Am i missing some settings, is the compiler not installed. I see Intel Advisor XE 2013, Intel Inspector 2013 and Intel VTune Amplifier 2013. Please advise.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Steve here's what appeared under Compillers in VS
$(IFortInstallDir)Lib
$(VCInstallDir)atlmfc\lib
$(VCInstallDir)lib
$(WindowsSdkDir)lib
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You didn't change the Show Progress property. Please do that, relink and show me the new buildlog.htm
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Interesting - it doesn't seem to be looking in the compiler's library folder at all.
Try this for now - in the project properties under Linker > General, put this in "Additional Library Directories":
C:\Program Files (x86)\Intel\Composer XE 2013\compiler\lib\ia32
Now try again. This is just a workaround - we still need to figure out why it isn't finding the library folder by default.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Any new recomendations Steve?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Are you on a 32-bit or 64-bit version of Windows? If 32-bit, then remove the (x86) from the path I gave you. Please also open that folder and check to see if ifconsol.lib is there.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page