Blog Archives

Sending Email in ASP.NET Using SMTP Authentication (VB.NET)

If you don’t need to use Authentication to send email, check out the code snippet Sending Email in ASP.NET 2.0 (VB.NET). If your web host requires that you use SMTP Authentication, some additional lines of code will need to be

Tagged with:
Posted in VB.NET

Sending Email in ASP.NET 2.0 (VB.NET)

Way back in 2001, I wrote ASP.NET Email Using VB for ASP.NET 1.x. ASP.NET 2.0 now uses the System.Net.Mail instead of the System.Web.Mail Namespace. Here is a quick snippet to get you started. Dim Message As MailMessage = New MailMessage()

Tagged with:
Posted in ASP.NET, VB.NET

IsNull in VB.NET

IsNull is not supported in VB.NET. Classic ASP users that used IsNull in VBScript should now use IsNothing. If Not Request.Form(“LastName”) Is Nothing Then ‘– Do something! End If

Tagged with: ,
Posted in VB.NET

SortedList Example for ASP.NET in C#

The SortedList object uses a key/value combination to sort a list. The SortedList can be databound to the following ASP.NET controls: asp:RadioButtonList asp:CheckBoxList asp:DropDownList asp:ListBox Our examples will bind a SortedList to an asp:ListBox. <asp:ListBox ID=”lsbPresidents” runat=”server” /> Numeric Sort

Tagged with: , , , ,
Posted in C#, VB.NET

My First ADO.NET Table

This article was written in 2002 and is based upon ASP.NET 1.0. The most common data centric task an ASP developer can do is create an HTML table from an SQL query. Below is an example of how to do

Tagged with: ,
Posted in ASP.NET, VB.NET