473,394 Members | 1,715 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

namespace confilct....

Hi,

I'm using the ADOMD.Net 9 in my web site + a third party web control which
used the ADOMD.Net 8.0.

Everytime I compile my web site in VS 2005, a referecne to the 8.0 library
is added this cause a namespace conflict.
So I must remove the 8.0 reference in the web.config and the site works fine
Only the compilation doesn't works, so its long to debug.

how can avoid this behavior?
can I bypass or explicitly reference a particular version of the assembly
in my code like:
Imports MyNameSpace=<version 9>.Microsoft.AnalysisServices

or can I do something in my web.config to insure that the third party
control will not add the assembly entry?

thanks.

Jerome.
Apr 19 '06 #1
2 1127
Let's say you have 2 namespaces, in 2 different assemblies: name1 and name2.
Each namespace has a class called foo. You are using both namespaces in a
Page. You are also using an instance of the name1.foo class in your Page. At
the top of the page, you have:

using name1;
using name2;

Now, later on down in the page, you declare a field that is of type
name1.foo:

private foo bar;

The compiler cannot tell from this whether you are referring to name1.foo or
name2.foo. To remedy this, change the code to read:

private name1.foo bar;

--
HTH,

Kevin Spencer
Microsoft MVP
Professional Numbskull

Hard work is a medication for which
there is no placebo.

"Jéjé" <willgart_A_@hotmail_A_.com> wrote in message
news:eV**************@TK2MSFTNGP02.phx.gbl...
Hi,

I'm using the ADOMD.Net 9 in my web site + a third party web control which
used the ADOMD.Net 8.0.

Everytime I compile my web site in VS 2005, a referecne to the 8.0 library
is added this cause a namespace conflict.
So I must remove the 8.0 reference in the web.config and the site works
fine
Only the compilation doesn't works, so its long to debug.

how can avoid this behavior?
can I bypass or explicitly reference a particular version of the assembly
in my code like:
Imports MyNameSpace=<version 9>.Microsoft.AnalysisServices

or can I do something in my web.config to insure that the third party
control will not add the assembly entry?

thanks.

Jerome.

Apr 19 '06 #2
no,

2 namespaces, 1 assembly but 2 different version of this assembly (version
8.0 and 9.0)!

there is no imports section in my code for the moment.

these 2 versions of the assembly contains the SAME namespace
But the version 9.0 provides more classes under the namespace.

"Kevin Spencer" <ke***@DIESPAMMERSDIEtakempis.com> wrote in message
news:ex**************@TK2MSFTNGP04.phx.gbl...
Let's say you have 2 namespaces, in 2 different assemblies: name1 and
name2. Each namespace has a class called foo. You are using both
namespaces in a Page. You are also using an instance of the name1.foo
class in your Page. At the top of the page, you have:

using name1;
using name2;

Now, later on down in the page, you declare a field that is of type
name1.foo:

private foo bar;

The compiler cannot tell from this whether you are referring to name1.foo
or name2.foo. To remedy this, change the code to read:

private name1.foo bar;

--
HTH,

Kevin Spencer
Microsoft MVP
Professional Numbskull

Hard work is a medication for which
there is no placebo.

"Jéjé" <willgart_A_@hotmail_A_.com> wrote in message
news:eV**************@TK2MSFTNGP02.phx.gbl...
Hi,

I'm using the ADOMD.Net 9 in my web site + a third party web control
which used the ADOMD.Net 8.0.

Everytime I compile my web site in VS 2005, a referecne to the 8.0
library is added this cause a namespace conflict.
So I must remove the 8.0 reference in the web.config and the site works
fine
Only the compilation doesn't works, so its long to debug.

how can avoid this behavior?
can I bypass or explicitly reference a particular version of the
assembly in my code like:
Imports MyNameSpace=<version 9>.Microsoft.AnalysisServices

or can I do something in my web.config to insure that the third party
control will not add the assembly entry?

thanks.

Jerome.


Apr 20 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: John L. Clark | last post by:
I am curious as to the rationale, and effect, of having default namespaces not applying (directly) to attributes (see http://www.w3.org/TR/REC-xml-names/#defaulting). Given an attribute without a...
25
by: kj | last post by:
Consider the following XML document: <?xml version='1.0' encoding='UTF-8'?> <bar:foo xmlns:bar='someuri'> <baz/> </bar:foo> What namespace does baz belong to? What is this namespace bound...
3
by: Mike Dickens | last post by:
hi, i'm sure this has come up before but havn't managed to find an answer. if i have the following xslt <?xml version="1.0" encoding="ISO-8859-1"?> <xsl:stylesheet method="xml" version="1.0"...
6
by: Don Wash | last post by:
Hi There! I just need some advice on Namespace management for creating reusable VB.NET applications. I would like my applications to have this namespace structure... Namespace MyCompany ...
8
by: Petter Reinholdtsen | last post by:
I ran into a problem on HP-UX 11.00 the other day, where it refused to compile a program using 'using namespace std;' at the top. The reason seem to be that the compiler refuses to accept 'using...
2
by: puzzlecracker | last post by:
after reading some of the post I found out something rather radical to my previous understanding: that when you do #include<iostream> #include<string> #include<vector> etc compiler puts...
6
by: clinton__bill | last post by:
Hi, I usually use "using namespace <namespace_name>" to reference a namespace. Today I run across a code, in its header file it has this, namespace SP1{ class C1; } While SP1::C1 is a...
7
by: Kevin Newman | last post by:
I've been toying with a namespace manager, and wanted to get some input. So what do you think? if (typeof com == 'undefined') var com = {}; if (!com.unFocus) com.unFocus = {}; ...
14
by: Tiraman | last post by:
Hi , I would like to use nested namespace . I have 3 namespace as dll's : Namespace A Namespace B Namespace C And i want to have some namespace that contain them all , some thing like
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.