Configure an application

T

Tony Johansson

Hi!

I'm reading a section in a book from Microsoft Press called .NET FRAMEWORK
2.0 Application Development Foundation.
about Installing and Configuring Application.

It says you might build an application with a given version of the Framework
but choose to run it with a different one.

What on earth should one want to do so ?

//Tony
 
A

Arne Vajhøj

I'm reading a section in a book from Microsoft Press called .NET FRAMEWORK
2.0 Application Development Foundation.
about Installing and Configuring Application.

It says you might build an application with a given version of the Framework
but choose to run it with a different one.

What on earth should one want to do so ?

Most likely: build on version N and run on a system that
only has version N+1.

Arne
 
T

Tony Johansson

Arne Vajhøj said:
Most likely: build on version N and run on a system that
only has version N+1.

Arne

What happen if you don't specify this in the configuration file ?
I mean that purpose that is serve?
<configuration>
<startup>
<supportedRunTime version="v1.1.4322 />
</startup>
</configuration>

//Tony
 
K

Konrad Neitzel

Hi Tony!

Tony Johansson said:
What happen if you don't specify this in the configuration file ?
I mean that purpose that is serve?
<configuration>
<startup>
<supportedRunTime version="v1.1.4322 />
</startup>
</configuration>

If you build the application with some other Framework, it will simply not
run if the system only has the 1.1 Framework even if it only uses stuff,
that is available on that framework.

So if you know that an application should run on other Frameworks, you can
also tell it to the framework inside the configuration file (as you have
shown).

(But I have to confess, that I didn't try it. It is simply my understanding
of what I read in the past.)

Konrad
 
A

Arne Vajhøj

What happen if you don't specify this in the configuration file ?
I mean that purpose that is serve?
<configuration>
<startup>
<supportedRunTime version="v1.1.4322 />
</startup>
</configuration>

http://msdn.microsoft.com/en-us/library/w4atty68.aspx

says

<quote>
If the <supportedRuntime> element is not present in the application
configuration file, the version of the runtime used to build the
application is used.
</quote>

There are also:

http://msdn.microsoft.com/en-us/library/w671swch.aspx

<quote>
The runtime examines the <supportedRuntime> Element element in the
application configuration file. If one or more of the supported runtime
versions specified in the <supportedRuntime> element are present, the
runtime loads the runtime version specified by the first
<supportedRuntime> element. If this version is not available, the
runtime examines the next <supportedRuntime> element and attempts to
load the runtime version specified. If this runtime version is not
available, subsequent <supportedRuntime> elements are examined. If none
of the supported runtime versions are available, the runtime fails to
load a runtime version and displays a message to the user (see step 3).

The runtime reads the PE file header of the application's executable
file. If the runtime version specified by the PE file header is
available, the runtime loads that version. If the runtime version
specified is not available, the runtime searches for a runtime version
determined by Microsoft to be compatible with the runtime version in the
PE header. If that version is not found, the process continues to step 3.

The runtime displays a message stating that the runtime version
supported by the application is unavailable. The runtime is not loaded.
</quote>

Regarding what is compatible then there are at least an example at:

http://msdn.microsoft.com/en-us/library/ms994381.aspx

see the "Application Load Mechanisms and Possible Issues" table.

I can not find a similar page for 2.0 versus 4.0, but I will
expect it to be the same that 2.0 stuff will run on 4.0 if
necessary.

Arne
 

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