MrSSS16
MrSSS16

Reputation: 473

Deploy c ++ program with vbscript?

I have created a windows application and a folder with the release executable and appropriate Dlls.

First problem is that I want to package it all into one setup.exe For this task I plan on using windows default iexpress application....(is there better software available for this...must be free though, since this is only for a university assignment)

Second problem is I want to structure the installation so that the actual program along with included libraries are saved in their disk drive, i.e program files(x86) for w7. And at the same time make a desktop shortcut so its easier to run and access for the user.

The issues arising with my second problem is:

Assignment due in 2 days so I would really be grateful if I could get this off my chest

Thx :)

Upvotes: 1

Views: 271

Answers (3)

rkosegi
rkosegi

Reputation: 14678

You may be interested in following SW:

I would recommend first option, it's free for your purpose, you don't need to buy professional license and you can make MSI package in 5 minutes.

Upvotes: 3

peter
peter

Reputation: 42207

You have an environment variable ProgramFiles with in it the path to this folder.

Doesn't include the software you used to build the exe and dll files an installer/packager ?

Otherwise I would search a free packaging program, it should be the easiest way, making the shortcut could also be done by this package. On the other hand if you want to use vbscript you could do it all from there too but your script would have to be executed by the user with administrative rights, not for the everyday user...

free packaging: Some googling gave me http://www.windowsnetworking.com/articles_tutorials/msi-packaging-tools.html, check it out

Upvotes: 0

Rost
Rost

Reputation: 9089

No, Program Files folder is common to the valid Windows installation. But you shall not assume that it's always C:\Program Files. You must use corresponding environment string to get program files folder:

  • %ProgramFiles% - to store 32 bit programs on 32 bit OS and 64 bit programs on 64 bit OS.
  • %ProgramFiles(x86)% - to store 32 bit programs on 64 bit OS.

VBScript has nothing to do with Visual Basic (VB.exe) itself. It's running by Windows Script Host and does not require any additional libraries. Windows Scripting Host is included by default into any modern Windows OS.

You just create script source file with extension .vbs and run it as any usual executable. Example of creating shortcut could be found here.

Upvotes: 2

Related Questions