What do I need Protected WithEvents for?

Posted by: Peter Lanoie at Sunday, May 23, 2004 1:18:24 PM in: ASP.NET 1.x
I've noticed "Protected WithEvents" in the declarations for my controls on an ASPX web form. What's this all about? What does it mean?
Read on ...

Change the CSS Class of an Object in Your Page

Posted by: Imar Spaanjaars at Tuesday, May 18, 2004 1:19:35 PM in: CSS
It's easy to change style information of any object in your HTML page. With a bit of JavaScript you can change, for example, the border, or background-color of a paragraph.
Read on ...

Retrieve the Current Run-Time Directory of the .NET Framework

Posted by: Imar Spaanjaars at Sunday, May 16, 2004 11:15:42 AM in: .NET General
This snippet shows you how to retrieve the directory of the "current" .NET Framework. The path returned is the location of the version of the .NET Framework that your application is using.
Read on ...

Regular Expression for a Strong Password

Posted by: Imar Spaanjaars at Sunday, May 16, 2004 10:33:00 AM in: .NET General
This snippet shows a Regular Expression for a strong password.
Read on ...

Change the Printer in Visual Basic 6

Posted by: Imar Spaanjaars at Sunday, May 16, 2004 10:30:43 AM in: Visual Basic 6
The following snippet shows you how to change the current printer with Visual Basic 6 code.
Read on ...

Preselecting an Item in a Drop-Down List

Posted by: Imar Spaanjaars at Saturday, May 15, 2004 10:01:45 AM in: JavaScript
The following JavaScript code can be used to preselect an item in a drop-down list.
Read on ...

How Do I Preselect an Item in a Drop-Down List?

Posted by: Imar Spaanjaars at Saturday, May 15, 2004 9:53:18 AM in: JavaScript
In HTML, it's pretty easy to preselect an item in a drop-down list. At design-time, or with a dynamic server page, at run-time at the server, all you need to do is add the selected attribute to the <option> element you want to select. If you want to select the item programmatically through JavaScript code, you'll have to follow a different route.
Read on ...

How Do I Get the Names of all Embedded Resources in an Assembly?

Posted by: Imar Spaanjaars at Friday, May 14, 2004 8:22:38 AM in: .NET General
Because the naming scheme of embedded resources is sometimes a bit awkward (you have to take the Default Namespace, folder names and resource file names into account), it can be useful to display a list of all embedded resources in your assembly with their Fully Qualified names. Put the following code in a method, like the constructor for your control for example, to get all the names in the Output window.
Read on ...

How Do I Allow My Web Application to Write to Files, Folders and Databases?

Posted by: Imar Spaanjaars at Sunday, May 09, 2004 4:52:33 PM in: Security
Many Web sites these days use databases or text files to save information. To be able to save this data, IIS, the Web server, needs the required permissions to write to the disk or database. This FAQ will explain how you should configure your NTFS disk or database so your Web application can write to it.
Read on ...

How Do I Determine the Security Account that IIS Uses to Run My Web Site?

Posted by: Imar Spaanjaars at Sunday, May 09, 2004 3:18:33 PM in: Security
It's important to understand the account that IIS is running under when you need to make changes to the security settings. If, for example, your Web application writes to files or to a database, you'll need to grant the correct permissions to the folder or database. Before you can change these security settings, it's important the know what account IIS is using. This FAQ details the various options available, both for "classic" ASP and ASP.NET applications.
Read on ... 12345678910111213141516171819202122232425262728293031