VB.net program does not start
Solved
thomasdoudou
Posted messages
38
Status
Member
-
thomasdoudou Posted messages 38 Status Member -
thomasdoudou Posted messages 38 Status Member -
Hello,
So here it is, I made a program in VB.NET (2010) that I created on Windows 7. After compiling and saving it, I run my .exe and my program launches well. Then I send my .exe to a friend who is also on Windows 7, and there, the program does not launch!
So I tested to make a program without buttons, without code, without anything, I pass it to my friend and this time the program launches ...
Thanks for your responses
So here it is, I made a program in VB.NET (2010) that I created on Windows 7. After compiling and saving it, I run my .exe and my program launches well. Then I send my .exe to a friend who is also on Windows 7, and there, the program does not launch!
So I tested to make a program without buttons, without code, without anything, I pass it to my friend and this time the program launches ...
Thanks for your responses
Related links:
- [VB.NET] Select entire line ListView
- changing language in vb.net
- Retrieve the result of a SELECT (VB.net)
- Éteindre le PC avec VB.NET peut être effectué en utilisant la commande suivante : ```vb Process.Start("shutdown", "/s /t 0") ```
- [VB.NET] Creating a PictureBox Collection
- Connecting to MySQL from VB.net version 8.0.28
11 answers
-
[Resolved] I will explain for those who had the same problem (I want to thank lermite222 who led me to the clue ;) )
So, after finishing your application, go to Project >> Properties [Your project name]
Then go to Publish and click on "Required components"
Check: Download required components from the component supplier's website
After that, check all the boxes where there is no question mark. (Those without a question mark are the ones installed on your machine)
After doing that, click "OK" and then click on "Publish Now" at the bottom
Choose where it will place your "publish"
Then once it is finished, go look for it, and EVERYTHING IN THERE IS IMPORTANT so if you want to install your project on a machine, you will need the stuff in "publish"
Then if you want to install your project, click on SETUP, the SETUP will only install the required components. Once it's finished, click on [Your project name] and it will install your project correctly
Thank you all for your help! -
Hello,
If you want to export your app to a machine that doesn't have VB.Net, you need to create an installer.
See you later
--
Experience teaches more surely than advice. (André Gide)
If you knock on a pot and it sounds hollow, it’s not necessarily the pot that’s empty. ;-)(Confucius)-
-
No, the installer will compress the exe, but also all dependencies and dlls.
Check with Inno Setup. -
-
-
-
It still doesn't work...
Clearer than that, you die...
What isn't working?
What did you do, try??
Experience teaches more surely than advice. (André Gide)
If you bump into a pot and it sounds hollow, it's not necessarily the pot that's empty. ;-)(Confucius) -
I tried to do an installation, it doesn't work and then, I modified the code, and still nothing. In fact, it happens on all the machines. When I launch it, I immediately get the error report.
Thank you for your help. -
-
The framework is installed, and it’s the latest one. But I think I found something... When a person installs Visual Basic, (the installation doesn’t just install Visual Basic but other things as well) once they have installed Visual Basic and its components... my program starts up.
But we need to know what the other component to install is (excluding the Framework which is already installed).
Thank you for your help.
Edit: When I open my project, I get "Initialization failure of the system"
Unrecognized configuration section system.serviceModel. (c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Config\machine.config line 134):
at System.Configuration.ConfigurationSchemaErrors.ThrowIfErrors(Boolean ignoreLocal)
at System.Configuration.BaseConfigurationRecord.ThrowIfParseErrors(ConfigurationSchemaErrors schemaErrors)
at System.Configuration.BaseConfigurationRecord.ThrowIfInitErrors()
at System.Configuration.ClientConfigurationSystem.EnsureInit(String configKey)
That said, I can ignore this error and continue with my project. -
Re,
With Inno Setup you create a ... Setup..
No need to install VB.net on other computers.
Copy your Setup onto a CD.
Run it on another PC.
Then you run your app like any other.
It should work.
See you later
Experience teaches more surely than advice. (André Gide)
If you bump into a pot and it sounds hollow, it's not necessarily the pot that is empty. ;-)(Confucius) -
You open Inno Setup, show it the exe you want to process, and it takes care of collecting the necessary dependencies for operation.
If your application uses auxiliary files like a database, you need to include it in the setup.
Be sure to read what is requested during the process.
See you!
EDIT:
Well, there's a much simpler way to do this (I hadn't tested it yet).
In VB2010, you load your project.
Then click on > Project >> Publish.. (your project name)
Just specify a directory.
The setup is done, you copy it to a CD/DVD (it might also work on a USB stick)
See you!
Experience teaches more surely than advice. (André Gide)
If you bump into a pot and it sounds hollow, it doesn't necessarily mean the pot is empty. ;-)(Confucius) -
I think it works! I'm going to test it on a friend's PC this afternoon and I'll let you know tonight!
-
So when I do the setup, okay
Then on my friend's computer, I start the setup, and it tells me to install Net Framework 4, I install it and then when I restart the setup it tells me to install: Microsoft.VisualBasic.PowerPack.Vs V 9.0.0.0
So at this point, do I still need Visual Basic? -
Well, I haven't done this installation since .Net but..
To add Microsoft.VisualBasic.PowerPack.Vs V xxxx (2010 is V10.0)
Before doing the setup, >> Properties of (the name of the project) >> Publish and check
Microsoft.VisualBasic.PowerPack.Vs V 10.0
Then redo the setup.
If anyone has already performed these maneuvers, please help the participant.
See you later
Experience teaches more surely than advice. (André Gide)
If you bump into a pot and it sounds hollow, it's not necessarily the pot that's empty. ;-)(Confucius)