.Net, ADO.NET, ASP.NET, C#, Database, DB Connection Example, Example Connection, Programming, SQL, SQL Server 2000, SQL Server 2005, SQL Server 2008, SQL Server 2012, Web Development, WebForms

Basic Example of using the ASP.NET FileUpload to Save into a Database

Here is a super-simple bare-bones example of an ASP.NET Web form page in C# that uses the .NET FileUpload component to allow a user to upload a file into a SQL Server database table. I’ve put this together as a template to show just how easy it is to do and how few lines of actual code the process actually requires. Surprisingly the examples I found online and at the Microsoft support site were incomplete or had errors, so this is my attempt at making things clear. Continue reading “Basic Example of using the ASP.NET FileUpload to Save into a Database”

Advertisement
.Net, ADO.NET, ASP.NET, C#, DB Connection Example, Example Connection, Excel, Excel 2003, Excel 2007, JavaScript, JQuery, Programming, Regular Expressions, Web Development

JQuery with ASP.NET: Save Copy / Paste Excel Data to a Database Table

Have you ever wanted to help your users move data from Excel to your Web application? In this article I will give an example in ASP.NET that takes copied Excel spreadsheet rows from the user’s clipboard and saves the information to a SQL Server database table.

Since ASP.NET runs at the server level, you will need to use JavaScript/JQuery to get the Excel information from the user’s clipboard. You will need to use a different command to get the information depending on the user’s browser. In this example, I code specifically for Internet Explorer, but this is just since I am giving an example. In a real-world application you would code for all of the major browsers. Continue reading “JQuery with ASP.NET: Save Copy / Paste Excel Data to a Database Table”