09 July 2008 09:19
Building on my previous article on importing text files of various formats to an Access database, here's how to do the same thing simply and efficiently with Excel files.
Viewed 79662 times
17 May 2008 09:48
There are a variety of options for connecting to Access databases within ASP.NET pages. This article attempts to cover the choices and offer recommendations for getting the best out of Access.
Viewed 95518 times
01 May 2008 11:06
This short article deals with the following common MS Access-related error messages:
Viewed 30444 times
01 May 2008 10:02
Quite often, I see questions asked about creating a simple login page for use with Access from people who don't want to take advantage of the built-in Forms Authentication framework within ASP.NET. The following samples show how relatively easy this is to accomplish.
Viewed 341245 times
30 April 2008 22:48
The unbelievably cryptic Operation Must Use An Updateable Query error is the bane of developers who are just starting out with Access and ASP.NET. You've done your code, plopped your database file in the App_Data folder (or at least, you should have done), and try to run a page that INSERTs or UPDATEs records, and it all stops dead. This brief article explains the cause of the error, and the steps required to stop it recurring.
Viewed 222472 times
13 November 2007 12:33
If you have just been directed to this page, it may be because you have just thread-jacked. If you are not sure what that means, read on for an explanation, and some guidance.
Viewed 914108 times
12 November 2007 15:15
Creating a search interface for one user-supplied value is pretty straightforward: a TextBox for input, a Button and some SQL that searches one or more fields where the values are LIKE '%' + @searchterm + '%' is all that is needed. While it works, this approach is not very flexible. For example, what if you wanted to search for an Employee whose last name contains "a", and don't want those where the first name or city contains "a"? The traditional solution to this is to dynamically construct the SQL statement based on what values were passed by the user. However, building the SQL string can get repetitive, boring and messy. Here is a cleaner way to allow the user to narrow down searches across multiple criteria with the use of optional parameters, and just 3 lines of programming code.
Viewed 27632 times
30 August 2007 10:29
If you want to find which CheckBoxes were selected in a multiple record DataBound control, the way that you you do it depends on the type of control you use. These examples demonstrate a CheckBox control being added to a GridView, Repeater and a DataList. For simplicity, I have placed all three controls on the same page, and used the Access version of theNorthwind database. One AccessDataSource control is used to bind the results of "SELECT [CategoryID], [Description], [CategoryName] FROM [Categories]" to all three controls.
Viewed 73083 times
25 August 2007 12:34
Viewed 55730 times
25 August 2007 10:32
Label controls in ASP.NET don't have a smart tag that allows you to select a data source, so at first glance, it is not easy to see how to bind a value returned from a SqlDataSource or AccessDataSource control to the label. Here's how to programmatically access the data returned by such a DataSource and apply it to a non-databound control.
Viewed 204209 times
21 August 2007 11:36
A list of standard ASP.NET web controls that implement INamingContainer
Viewed 28441 times
18 August 2007 23:12
I like reading Scott Guthrie's blog. Trouble is, I get so busy, I forget to go over there and have a look to see what's new. I was searching for something the other day, and stumbled across someone else's blog (I forget whose), but I noticed that they had the 5 most recent items in Scott's blog embedded in their home page. It was only then that I discovered that Scott Mitchell has written a whole load more tutorials on Data Access, and that these have been available for a while. So I got to thinking that I should add a feed from Scott G's site onto the home page here, so I can be updated more quickly. Here's the bare bones of how I did it.
Viewed 13181 times
10 August 2007 21:33
Iterating the contents of a folder is straightforward using classes from System.IO, and listing them as links to the actual file just requires a bit of html added to each file name.
Viewed 22099 times
02 August 2007 23:41
A question that often comes up in forums is how to export data to a CSV file, or other text format. Here's a method that takes data from a DataReader and writes it to a file.
Viewed 47056 times
27 July 2007 14:24
This item could also have been entitled "Displaying Master-Detail Data" or "Displaying Categorised Data", but the principal is the same: you have what are essentially headings or categories, and a group of entries that belong to each heading that you want to display. Typical examples would include the Models of cars by Manufacturer, or Employees by Department. Here's how to do it quite simply using nested Repeaters.
Viewed 51439 times
In response to Migrating Classic ASP To ASP.NET Razor Web Pages Part One- Razor Syntax And Visual Basic
Nicely written article, just what I wanted to get me started, I am going to start working on a this...
In response to Adding A Controller
I am really new to everything and just started programming. I really need help in my project since I...
In response to Request.Form Is Empty When Posting To ASPX Page
It worked. Thank you!...
In response to Reading Excel Files Without Saving To Disk In ASP.NET
Muchas, muchas, gracias. Thank you so much from Dominican Republic....
In response to How To Send Email In ASP.NET MVC
Hello Sir, Great post. Just a quick question, is it possible if we can ask a client to save in an...
In response to Windows Authentication With ASP.NET Web Pages
I've been using this advise for quite a while. Today I was setting up a .NET 4.6.1 site and it drove...
In response to iTextSharp - Working with Fonts
Thanks a lot for this excellent series on iTextSharp....
In response to Simple File Download Protection with ASP.NET
Mike, Thank you for taking the time to write this. It really helped me - though I could not out a...
In response to Solved - The Microsoft.ACE.OLEDB.12.0 provider is not registered on the local machine
Installing Microsoft Access Database Engine 2010 64 bit helped me. Thanks A lot!...
In response to ASP.NET MVC 5 with EF 6 - Working With Files
Wonderful example. I have it all working. I would like to add the image to each row of the index you...