tags:

views:

92

answers:

5

Hi,

I have a vb app working now but many users have complained to me that it requires .net library installed. Is there a way to bundle it with my program without having a seperate exe?

A: 

If you use the packaging tool which comes with the VB6 IDE (can you really call it that?), it will install all the dependencies with the app. However, I'm not sure that's the real problem here because VB6 doesn't depend on the .NET framework.

tster
I must be using some other vb(im new to this stuff)
Neb
@Neb, what IDE are you using? Visual Studio 2005, Visual Studio 2008, etc.?
tster
Why the busting on the VB6 IDE? That thing was awesome for its time.
Chris Farmer
@Chris Farmer, because I still have to use it from time to time and it's random crashing, inability to cope with threads, and ability to corrupt frx files rendering your form uncompilable is legendary.
tster
@tster, @Chris. I've been using the VB6 IDE heavily for about 10 years, I can only remember one incident of file corruption and no crashes. I've had more crashes with VS2008 (three). Just my personal experience.
MarkJ
@MarkJ, a case of "works on your machine" I guess.
tster
A: 

If you're using VB.NET, then it's not possible, VB.NET is too reliant on .NET framework for everything.

However, you might want to backport your code into VB6, which does not require .NET framework.

Lie Ryan
-1 at the very idea of moving BACKWARDS to VB6
tster
why the -1? moving back to VB6 is the only way to ship VB application without .NET; I'll be happy to be proven wrong.
Lie Ryan
VB6 is a completely different from VB.Net, they might share syntax, and there are a lot of helper classes to make it easy to upgrade VB6 -> VB.Net, but there is nothing going the other way, so unless he's used a very limited subset of the .Net framework it would mean that he'd have to rewrite large parts of the app and what he'd end up with is an app for an unsupported language/dev environment.
ho1
VB6 also requires its runtime to be present on the target machine. It doesn't really solve anything.
Hans Passant
@Hans VB6 does require its runtime: but it comes preinstalled with Windows (on Windows 2000 and later as far as I can remember) so you can just XCOPY deploy a simple VB6 app. You can even XCOPY deploy a complicated VB6 app if you use reg-free COM
MarkJ
@Mark: there were 7 versions, Windows 2000 certainly wouldn't have the right one.
Hans Passant
@Hans VB6 does require its runtime: but the runtime comes preinstalled with Windows on all versions from Windows 98 to Windows 7. So you can just XCOPY deploy a simple VB6 app. You can even XCOPY deploy a complicated VB6 app if you use reg-free COM. Having said all that, backporting from VB.Net is likely to be hard and IMHO isn't that sensible
MarkJ
It's also worth pointing out that the .NET framework is also preinstalled on anything Vista and newer.
Adam Robinson
and I would assume that he asked this question since he had to support older Windows where .NET hasn't been installed by default
Lie Ryan
@Lie Ryan: It could also be something like that he's used .Net 4.0 in his app, so it's not installed by default on any Windows (yet).
ho1
+1  A: 

I'm assuming that you're using VB.NET (rather than just VB, as your tags suggest). In this case, no, there is no possible way to eliminate needing the .NET framework. While you can list it as a prerequisite and include it with your setup project, you cannot eliminate the dependence upon it.

Adam Robinson
A: 

Take a look at VMWare ThinApp http://en.wikipedia.org/wiki/VMware_ThinApp. It's a commercial appplication, but it's the only thing I know of that might do what you want.

sarme
A: 

I've found that the biggest complaint with users (and biggest source of installation confusion) is having to install a separate runtime for .NET, along with the application. Especially if they have to go through 2 hours of Windows Update downloads and reboots to obtain it! Creating an setup package that includes the .NET runtime and installs this seamlessly, along with your application, should make things go much smoother for your users. Most people expect to have to install applications first before they use them anyway.

Creating a simple setup application is easy in Visual Studio. See Microsoft's guide here: http://msdn.microsoft.com/en-us/library/k3bb4tfd.aspx

There are other third-party installer programs you can use, but I'll mention here that my favorite is definitely Inno Setup, which I highly recommend. The website is here: http://www.innosetup.com/isinfo.php. You can write a simple script that will automatically install the current version of the .NET framework, if the user doesn't already have it installed.

Cody Gray
I am using inno setup, thanks!
Neb