Solved

Error message when App is loading

Posted on 2006-06-13
5
258 Views
Last Modified: 2010-04-23
When I run my app on MY computer with Visual Studio .Net 2005, it runs fine. (.Net 2005 is also what I programed my app in)  BUT, when I run my app on another computer, I get an error message.  This is the message:

To run this application, you first must install one of the versions of the .Net framwork:
v.2.0.50727
Contact your application publisher for instructions about obtaining the appropriate version of the .Net Framwork.

It's a simple application.  When the CD is put in, it autoruns a startup window that looks at the system they're using and sees if they have Adobe 7.0 viewer.  If not, it installs it for them.  (THIS IS WORKING FINE)
After that, the startup window has a link to run a viewer app that I made.  (A completely differet .exe located on the CD)  It's when I click on this link that the error comes up.  

What is this error and how can make it stop without letting the user know.  This app is going out to 30 people and they are very very computer dumb.  I also won't know if they have this .Net framwork or not.

I'm using an XP machine with Service Pack 2 installed.  Please help.
0
Comment
Question by:Heyitsjoe80
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 52

Expert Comment

by:Carl Tawn
ID: 16896863
The error message says it all - the user doesn't have the 2.0 version of the .Net framework installed.

You can get a redistributable version of the .Net framework that you can ship/install with your app.
0
 

Author Comment

by:Heyitsjoe80
ID: 16897070
My app does not install.  It just runs a .exe.  Does that matter?
0
 
LVL 52

Expert Comment

by:Carl Tawn
ID: 16897101
Yes. If it is written for the .Net framework then it requires the .Net framework to run. Even tho it is run from the CD the actual assembly is still loaded into memory on the local machine and still requires access to the .Net framework libraries.
0
 

Author Comment

by:Heyitsjoe80
ID: 16897407
I'm sorry, let me rephrase that.  Since my app does not install..how can I get the .Net framework to install without the user knowing?  I understand that I need it to run the app.  I just don't want to hand this out to people and have them completely dumbfounded when the error pops up.
0
 
LVL 1

Accepted Solution

by:
thebatdude earned 500 total points
ID: 16897645
1. First the .NET Framework requires administrative level permissions in order to be installed.
2. You can specify command line arguments on the dotnetfx.exe which will cause it to install in an "unattended" fashion (without the users need to interact with the installation), but if the currently logged in user is not an administrator on the computer, this will fail.
      2.a If the users are on your corporate network, there are strategies to get around this:  see this article on deploying the .NET framework:  http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnnetdep/html/redistdeploy1_1.asp
3. If the users are all administrators then on your cd include the dotnetfx.exe for whatever version of the .NET framework your application requires, and autorun a batch file (.cmd file) to launch this:
dotnetfx.exe /q:a /c:"install /l /q"

This will install the .NET framework in silent mode.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Article by: Kraeven
Introduction Remote Share is a simple remote sharing tool, enabling you to see, add and remove remote or local shares. The application is written in VB.NET targeting the .NET framework 2.0. The source code and the compiled programs have been in…
If you're writing a .NET application to connect to an Access .mdb database and use pre-existing queries that require parameters, you've come to the right place! Let's say the pre-existing query(qryCust) in Access takes a Date as a parameter and l…
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question