Hi everyone,
I am trying to make a link between eviews and matlab 2016. I did Regcomponents issue. But I do not know how should I proceed in Matlab in order to create a reference to the Eviews 9 library. Please help.
thanks.
Sam
Call Matlab from Eviews (COM Automation)
Moderators: EViews Gareth, EViews Moderator, EViews Jason, EViews Matt
Re: Call Matlab from Eviews (COM Automation)
Hi.
Have you tried:
If that works you can use:
to execute commands in EViews from Matlab.
/K
Have you tried:
Code: Select all
handle=actxserver('Eviews.Manager');
application=handle.GetApplication;Code: Select all
application.Run('cd C:\MyEViewsHacks\');/K
-
EViews Steve
- EViews Developer
- Posts: 844
- Joined: Tue Sep 16, 2008 3:00 pm
- Location: Irvine, CA
Re: Call Matlab from Eviews (COM Automation)
salahaddin:
Your question is confusing...
Your subject header says "call matlab from eviews", but your question makes it sound like you're trying to call eviews from matlab.
Which is it?
If you're trying to control matlab from eviews, you need to make sure matlab's COM objects are properly registered with Windows. In particular, the matlab object whose progid is: MATLAB.Application. EViews can show you which matlab objects it can find in the registry if you go the Options/General Options/External program interface. Look in the MATLAB dropdown. If you don't see anything in that list it means MATLAB COM isn't properly registered on your machine. You'll have to look up matlab help on properly registering matlab com components.
If you're trying to control eviews from matlab, I would try using Excel as the controlling program first as all of our examples in our COM Automation whitepaper use Excel. To make sure EViews COM is properly registered you would use the REGCOMPONENTS command to bring up the Component Registration dialog, then click "Yes (All)" to re-register everything. If you run into problems, make sure your calling program is the same "bitness" as the version of EViews you're trying to control. In other words, if you're using Excel 32-bit (or MATLAB 32-bit), make sure you have EViews 32-bit installed as well. This doesn't mean 64-bit EViews won't work, but if you ever had an older 32-bit EViews application that was uninstalled, this could cause Windows to think the 32-bit COM objects are missing...
Once you get EViews COM automation working with our Excel examples, you can try it with MATLAB and it should work the same.
Steve
Your question is confusing...
Your subject header says "call matlab from eviews", but your question makes it sound like you're trying to call eviews from matlab.
Which is it?
If you're trying to control matlab from eviews, you need to make sure matlab's COM objects are properly registered with Windows. In particular, the matlab object whose progid is: MATLAB.Application. EViews can show you which matlab objects it can find in the registry if you go the Options/General Options/External program interface. Look in the MATLAB dropdown. If you don't see anything in that list it means MATLAB COM isn't properly registered on your machine. You'll have to look up matlab help on properly registering matlab com components.
If you're trying to control eviews from matlab, I would try using Excel as the controlling program first as all of our examples in our COM Automation whitepaper use Excel. To make sure EViews COM is properly registered you would use the REGCOMPONENTS command to bring up the Component Registration dialog, then click "Yes (All)" to re-register everything. If you run into problems, make sure your calling program is the same "bitness" as the version of EViews you're trying to control. In other words, if you're using Excel 32-bit (or MATLAB 32-bit), make sure you have EViews 32-bit installed as well. This doesn't mean 64-bit EViews won't work, but if you ever had an older 32-bit EViews application that was uninstalled, this could cause Windows to think the 32-bit COM objects are missing...
Once you get EViews COM automation working with our Excel examples, you can try it with MATLAB and it should work the same.
Steve
Who is online
Users browsing this forum: No registered users and 2 guests
