Visual Studio - VB.Net References

  • Thread starter Thread starter Mythran
  • Start date Start date
M

Mythran

I have web controls installed in the C:\Program Files\Common
Files\Company.Name directory and reference them in my VB.Net web project
using the .Net IDE. I do the same for each web control, but some of my web
controls display as lowercased. I checked the vbproj file for the web
project and noticed that the reference stored for some of the files are
lowercased in the <Reference> section. Why does it not add the file names
to the project file as they are on the file system? When they are copied to
the bin directory, they have the correct case in the name...as they are when
they are compiled before referenced...but some of them are and some of them
aren't referenced with the correct case...what gives? Just an
annoyance...sorry if this is posted in the wrong group(s)...don't know where
else to post something like this :)

Thanks,
Mythran
 
I have web controls installed in the C:\Program Files\Common
Files\Company.Name directory and reference them in my VB.Net web project
using the .Net IDE. I do the same for each web control, but some of my web
controls display as lowercased. I checked the vbproj file for the web
project and noticed that the reference stored for some of the files are
lowercased in the <Reference> section.

The uppercase vs lowercase is not controlled by the filename of the DLL. It
is controlled by the namespaces and classes that are declared within it.

For example, suppose I make a Class Library project like this

Namespace foo

Public Class bar
' whatever is in here is irrelevant to this discussion
End Class

End Namespace

Now, I build the Class Library DLL.

Then I flip over to the Windows Explorer and hit it's bin directory and
rename the DLL to "FooBar.DLL"

When I reference it in a client project I will see a lowercase Namespace
"foo" and a lower case class named "bar", because that's the way they were
originally declared inside the class library.

A word of advice -- even though it's an annoyance, if you DO have the source
code for this class library, be careful and thoughtful about changing the
case of the declarations in it. This is because languages like C#, J# & C++
are case sensitive, and if you have client applications in those languages
that use this library, if you change the case of the namespaces or class
names and then redeploy, it might break any C# / J# / C++ clients that use
it.
--
Peace & happy computing,

Mike Labosh, MCSD

"When you kill a man, you're a murderer.
Kill many, and you're a conqueror.
Kill them all and you're a god." -- Dave Mustane
 
Checked all Namespace and class names in the assemblies that are referenced
as lowercase...all namespace declarations, class names, et cetera are in
their proper casing...none are lowercase...

So I did a search in the directory for all files that contain the lowercase
name....0 hits..the assemblies have the correct casing...another problem
maybe?

Mythran
 

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

Back
Top