VBC and Formualr with Icon

S

sommwerweide

I have created an simple visual basic windows application with the
visual studio 2003. But i want to compile this with the vbc compiler
(.Net framework 1.1 SP1) an not with the visual studio. Now i have the
following issue: My form is using an icon, which i have defined in the
properties of this form.

##########################################################################
Resgen Form2.resx Form2.resources


VBC /target:WinExe /out:win2 /main:win2.Form2 /rootnamespace:win2
/reference:System.dll,System.Data.dll,System.Drawing.dll,System.Windows.Forms.dll,System.XML.dll
/resource:Form2.resources
/imports:Microsoft.VisualBasic,System,System.Collections,System.Data,System.Drawing,System.Diagnostics,System.Windows.Forms
/verbose /debug- /debug:full /warnaserror+ "AssemblyInfo.vb"
"Form2.vb"
##########################################################################

The compile works fine, but when i start the exe i will receive the
following exception:

##########################################################################
An unhandled exception of type
'System.Resources.MissingManifestResourceException' occurred in
mscorlib.dll

Additional information: Could not find any resources appropriate for
the specified culture (or the neutral culture) in the given assembly.
Make sure "Form2.resources" was correctly embedded or linked into
assembly "win2".
baseName: Form2 locationInfo: win2.Form2 resource file name:
Form2.resources assembly: win2, Version=1.0.2032.24458,
Culture=neutral, PublicKeyToken=null

##########################################################################

When i compile the application with the visual studio, the exe works
fine! It works also via the vbc compiler, when i remove the icon from
the form!

Please help me by solving this problem.

Jens
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top