installing addins

For questions regarding programming in the EViews programming language.

Moderators: EViews Gareth, EViews Moderator, EViews Jason, EViews Matt

tvonbrasch
Posts: 569
Joined: Fri Apr 15, 2011 5:35 am

installing addins

Postby tvonbrasch » Thu Oct 16, 2014 11:55 am

Hi

I have made a program that is supposed to automatically install all the addins i have in a particular folder (see below). But when i run it, I have to confirm manually that I want to replace the addin (if it already is installed), see attached Word file. Is there a way (command) so that I do not have to do this manually?

Thomas

close @all
'program installs all the addins in addin directory

'each addin must be placed in a subfolder, and the installation file must have the structure:
' name_install.prg

'a) finding folder names and storing the names in the txt file folders
%dir= "C:\tvb\eviews\addins"
cd %dir
shell(out=addins) dir /s /b /o:n /ad > {%dir}\Folders.txt

'b) installing addins
wfopen(type=text) ".\folders.txt"

'find length of %dir string
!dir=@len(%dir)+2
for !i=6 to @obssmpl
%name=@mid(series01(!i),!dir) 'find name of folder
if @folderexist(%name)=1 then 'check existence of subfolder
%subdir= %dir+"\"+%name+"\" 'name of subdirectory
cd %subdir
string a=%subdir
%filename=%name+"_install.prg" 'name of installation file
if @fileexist(%filename) =1 then 'if installation file exist
%dirname=%subdir+%filename
exec %dirname 'execute installation program
endif
endif
cd %dir
next
Attachments
eviews addin replace.docx
(274.69 KiB) Downloaded 290 times

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13604
Joined: Tue Sep 16, 2008 5:38 pm

Re: installing addins

Postby EViews Gareth » Thu Oct 16, 2014 12:01 pm

Not currently, no.


Return to “Programming”

Who is online

Users browsing this forum: No registered users and 2 guests