Stories Tagged with 'ASP.NET'


How to share Forms Authentication between a 1.x Site and a 2.0 Site in the Same Domain

There are several blogs that have discussed how to share an auth cookie between sites in a farm and how to do a true single-signon for a domain. Mark Brooks pointed me to these that help a lot:

Now the trick is to do it between a 1.x and a 2.0 site in the same environment (but in different IIS Applications).  The trick is to create a <machineKey /> entry in both web.configs.  Pete Bromberg has a nifty little web page that will help you generate one to use for both:

New Article: "Creating a Custom ASP.NET Profile Provider"

Url: http://www.theserverside.net/articles/showartic...

Compile ASP.NET 2.0 Site to One Assembly!

Url: http://forums.asp.net/1039804/ShowPost.aspx

Nasty ASP.NET 2.0 Bug...Postponed?

Url: http://lab.msdn.microsoft.com/productfeedback/v...

I've been working on some ASP.NET 2.0 code for the last few weeks and ran into a bug that (in my opinion) is particularly nasty.  If you are comfortable with the 1.x model at all, you're likely to run into it.  In the 1.x model, all code-behind classes were compiled into a single assembly.  So you could:

Problems Creating Custom DataSource Enabled Controls in ASP.NET 2.0

Url: http://lab.msdn.microsoft.com/productfeedback/v...

I find it unfortunatle that Microsoft has made is way too difficult to write your own DataSource enabled controls.  Deriving from DataBoundControl, but it still does not seem to be a way to synchronously get the data from the DataSource.  In a DataBoundControl control you can get the DataSourceView like so:

Rewriting ADOGuy.com: Part 1 - Requirements

For the new wildermuth.com, I have the following requirements:

I am sure there  are more, but those are the core of the new requirements.  Tune in tomorrow to start matching requirements with solutions...

Re-writing ADOGuy.com for ASP.NET 2.0

Back in the day when ASP.NET shipped, I converted this site from the existing ASP based site.  As an exercise to really bring in some new features I've wanted and to lose the ASP legacy (I actually still have a page or two that uses string concatenation to put together HTML Tables), I want to do a full re-write of the site. 

I use a process where I begin with the requirements, then the data, then the code (no big surprises there).  My goal is to blog through each stage of this process and hopefully help my readers learn a bit about an ASP.NET 1.x to ASP.NET 2.0 conversion.

Master-Detail in ASP.NET 2.0 is Pretty Cool

Button.OnClientClick() in ASP.NET 2.0 Rocks...

This new property (*not* event), allows you to wire up clientside code to be executed before the server-side onclick is handled.  In the old days we had to do this manually.  For example, this is how you would hook up a simple confirmation dialog:

This allows you to cancel the server-side event if the user says nope!  Cool!

ASP.NET 2.0: How SqlProfileProvider Stores its Data...

This probably isn't entirely correct since I am just looking at the output (e.g. the database rows) to determine this.  For each object in profile (i.e. Users), there is a single row in the aspnet_Profile table.  This table is made up like so:

The three middle columns are used to store the properties and their values.  PropertyNames stores a list of properties with hints on how to retrieve it from the String or Binary column.  For example:

Why are ASP.NET 2.0 Projects so different from regular projects...

I am working on a portal project with ASP.NET 2.0 and I am loving it.  Lots of stuff is in the box that I need.  The project is using VB.NET so I wanted to make sure that everything was Option Explcit On and Option Strict On...but since it is a Web Application, the normal property pages are nowhere to be found (unless I am missing it).  If I create any other project type (I think), I can look at the project property pages and see the Compile tab:

VB.NET Property Pages

New ASP.NET 2.0 Things I love!

I've been digging deep in to ASP.NET 2.0 the last couple weeks and I have been pleasantly surprised by a number of nice changes that probably didn't make the new features lists:

In addition, I was surprised by the intuitive forms authentication controls.  I was using the PasswordReminder control and wanted to capture the reminder and change the password to reset the password instead of remind them of their password since we were just storing the hashes.  But after digging in deep, I found out that since I setup the personalization to store as hashes, it was resetting the password. 

Postposed Features of ASP.NET 2.0

Url: http://msdn.microsoft.com/asp.net/whidbey/beta2...

Of particular interest is the DataSetDataSource object which is being postponed.  Though you can use the ObjectDataSource to bind to a Typed DataSet so it's not that much of a death-knell.  Check it out...

Community Server 1.0 Released!

Url: http://www.communityserver.org/

MetaBuilders ASP.NET Controls

Url: http://www.metabuilders.com

I just wanted to give a shout out to Andy Smith of MetaBuilders ASP.NET controls.  I regularly use his DialogWindow and FirstFocus controls.  He has a number of controls on his site that are just great, but I can only speak for those two.  My $0.02 review of them are:

Top 10 Web Application Security Problems

Url: http://prdownloads.sourceforge.net/owasp/OWASPT...

Three Tier ASP.NET Apps

I hear from a lot of readers that they are creating 3-tier ASP.NET apps and I always wonder if they know where the middle tier is.

In my opinion, the web server is the middle tier and client tier is the browser. Creating another set of machines to host the data layer isn't really necessary and, in fact, hosting the data layer on the web server is easier to scale. We know how to scale out web servers. Inventing a new set of machines forces you to figure out how to scale them out and it does not increase your scalability by scaling out both the web server and a fourth tier.

Shawn
Shawn Wildermuth
Author, Teacher, and Coach




My Courses

Wilder Minds Training
Vue.js by Example (New Lower Price)
Bootstrap 4 by Example (New Lower Price)
Intro to Font Awesome 5 (Free Course)
Pluralsight
Building an API with ASP.NET Core (New Course)
Building a Web App with ASP.NET Core, MVC6, EF Core, Bootstrap and Angular (updated for 2.2)
Less: Getting Started (New)
Using Visual Studio Code for ASP.NET Core Projects
Implementing ASP.NET Web API

Application Name WilderBlog Environment Name Production
Application Ver v4.0.30319 Runtime Framework x86
App Path D:\home\site\wwwroot\ Runtime Version .NET Core 4.6.27617.04
Operating System Microsoft Windows 10.0.14393 Runtime Arch X86