The .NET-Framework 3.5 SP1 is available in our hosting environment. Your account is provided with ASP.NET functionality as standard.
In ASP.NET, all the standard functions of .NET technology are still supported, i.e. as they are provided by Microsoft, with a number of expansions in addition to this.

More information about ASP.NET and the .NET Framework can be found at the .NET Framework Developer Center.

In this .NET-Framework 3.5 SP1 the following components are included as standard, among others, and are therefore not installed separately:

Microsoft Silverlight is a multi-browser, multi-platform and multi-device plugin to display the next generation of .NET-based media and interactive applications for the Web.

ASP.NET Ajax (Asynchronous Javascript And XML) is a free framework which can be used to quickly create a new generation of more efficient, more interactive and personalised web applications, supported by the most popular browsers.

Information about Ajax can be found at:

Trust Level

In the VEVIDA hosting environment, the ASP.NET 3.5 SP1 .NET-Framework runs in a Partial Trust environment, which is comparable to Medium.

This means, for example, that it is not possible to read or write outside the application folder, to overwrite server configuration settings such as httpRuntime, or to open sockets / ports. Anything of this kind (an error related to Code Access Security) will give a SecurityException or Configuration Error.

A SecurityException means that the application is trying to perform an action that is not permitted by the configuration.

Applications (assemblies, or .dlls) must be compiled with AllowPartiallyTrustedCallersAttribute, and be provided with strong names [link 2].

The Microsoft Development Network has more information about (the use of) ASP.NET, Partial Trust and Code Access Security. For example:

And also:

Development software (Microsoft Express versions):

Application folders

The web root folder (www) is a so-called application folder as standard. If you want to place a second, separate application in a subfolder, this folder must first be set up as an application folder.

You can inform us of this via MyVEVIDA. We will be happy to set up the folders for you.

ASP.NET and Frontpage

When you use ASP.NET you can in principle no longer use the FrontPage Server Extensions (FPSE). Frontpage has the characteristic of resetting NTFS rights, changing the permissions for the account under which the ASP.NET process runs.

Unfortunately there is only one (1) way to resolve this: By deleting the FPSE and fully resetting all the rights on the website. With this, any write permissions that have been assigned to folders and files are lost. Through MyVEVIDA you can inform us that the permissions need to be restored for the use of ASP.NET.

Installed version

Using the script below, you can call up what ASP.NET version is installed on the server upon which your website is hosted.

<%@ Page Language="VB" EnableSessionState="False" EnableViewState="False" Trace="False" Debug="False"%>
<script runat=server>
Sub Page_Load(Sender as Object, E as EventArgs)
Response.Write(".NET framework version: " & System.Environment.Version.ToString())
End Sub
</script>

It is recommended to develop applications in the same version as is installed.

Trace and Debug

During the development of your applications, you can trace possible errors and correct them by using debugging:

<%@ page debug="true" %>

You can also use this for the whole website by modifying web.config. By using different web.config files on the development server and the production server, you can ensure that the incorrect code is never shown on the production server, and always on the development server. The example below ensures that the incorrect code is always displayed (unless otherwise indicated on the page by means of the declaration above).

<configuration>
  <system.web>
    <compilation debug="true"/>
  </system.web>
</configuration>

Information about the processing of the page can be seen by including the following in your page:

<%@ page trace="true" %>

You can also turn this on or off for the whole website in the web.config. In this way you can indicate whether the trace information is only visible locally, or also for external web browsers. The former is the case in the web.config below.

<configuration>
  <system.web>
    <trace enabled="true" localOnly="true"/>
  </system.web>
</configuration>

We advise you to turn off the Trace and/or Debug command in the production environment. This will cause unnecessary load, and your customers will see all kinds of strange codes.

URL Mapping in ASP.NET 2.0

URL Mapping is new in ASP.NET 2.0 and is used to be able to use an alias as a URL. This can be very useful when you develop a page that is dependent on a parameter in the query string (for example http://www.example.org/default.aspx?pageid=1 for the homepage). You want the visitor to see http://www.example.org/home only.

The section below in the web.config indicates that when calling up http://www.example.org/home, the visitor actually calls up http://www.example.org/default.aspx?pageid=1. It is also possible to enter a different page name (e.g. profile.aspx) for the url default.aspx?pageid=4.

<urlMappings enabled="true">
  <add url="~/home" mappedUrl="~/default.aspx?pageid=1"/>
  <add url="~/blog" mappedUrl="~/default.aspx?pageid=2"/>
  <add url="~/faq" mappedUrl="~/default.aspx?pageid=3"/>
  <add url="~/profile.aspx" mappedUrl="~/default.aspx?pageid=4"/>
</urlMappings>

In the code behind file for default.aspx, you can then reach the page as if it was called up directly. The code below looks at what page was called up.

switch (Context.Request["pageid"]){
case "1" :
  lblOut.Text = "Home";
  break;
case "2":
  lblOut.Text = "Blog";
  break;
case "3":
  lblOut.Text = "Faq";
  break;
case "4":
  lblOut.Text = "Profile.aspx";
  break;
default:
  lblOut.Text = "Default.aspx";
  break;
}

The zip file attached contains the web.config and code above. Download
Source: RichardSoeteman.NET

Note

If you have a comment on this article, please send it to us via the Support module at MyVevida.

« Back

Customer service

Cannot find what you are looking for? Please contact our customer service:

We are glad to be of service.