SharePoint, XBOX, .NET, Technology - What I am reading

    [Home] [Recent] [Site Map] [SharePoint] [XBOX]

   

4GuysFromRolla.com Headlines

6/6/2007 Personalizing RSS Feeds with ASP.NET 2.0

Really Simple Syndication (RSS) is a common XML standard for syndaicating web content. It is typically used by content-producing sites to offer a machine-readable version of the latest headlines. For example, news sites like CNN.com and MSNBC.com offer RSS feeds for breaking news; most blog software includes RSS support that syndicates the blogger"s most recent posts. Since its inception, RSS has radically increased in popularity; today it is hard to find a content-producing website that does not offer at least one RSS feed.

While RSS can be used to provide a single encompassing syndication feed for a website"s content, users oftentimes are interested in RSS feeds that syndicate content catered to their specific interests. They don"t necessarily want to see every article, blog post, or news item a web site offers. Instead, a particular visitor to CNN.com might only be interested in international news, whereas another might only want to track the latest business-related news headlines. Websites that provide specialized RSS feeds do so by offering different links for RSS feeds on different topics. In this article, we will look at an example of how to provide dynamic and customized RSS feeds in an ASP.NET 2.0 application. Read on to learn more!
Read More >

5/30/2007 Rolling Your Own Website Administration Tool - Part 2

To help administer users, roles, and authorization settings, ASP.NET 2.0 includes the Web Site Administration Tool (WSAT), which is available from Visual Studio 2005 by going to the Website menu and then choosing the ASP.NET Configuration option. Launching the WSAT from Visual Studio, however, allows only local websites to be administered. Such restrictions are limiting when hosting a website remotely with a web hosting company. Consequently, I decided to build my own WSAT-like tool from the ground up. Part 1 of this article series provided an overview of this application and a look at the user management side of things.

This second and final installment looks at the remaining pieces of the custom WSAT application in detail: role management and specifying access rights. The complete application can be downloaded from the end of this article. For instructions on using my custom WSAT in a new or existing web application, refer back to the "Using My Custom Website Administration Tool" in Part 1. Read on to learn more about my custom WSAT"s role management and access rights capabilities!
Read More >

5/23/2007 Rolling Your Own Website Administration Tool - Part 1

Forms-based authentication combined with ASP.NET 2.0"s Membership and Roles systems makes creating and managing user accounts incredibly easy. I continue to be amazed at how the login-related Web controls encapsulate the array of tasks that I had always had to code by hand in classic ASP.

To help administer users, roles, and authorization settings, ASP.NET 2.0 includes the Web Site Administration Tool (WSAT). WSAT is available from the Visual Studio 2005 Website menu via the ASP.NET Configuration menu option. Launching the WSAT from Visual Studio, however, allows only local websites to be administered. Such restrictions are limiting when hosting a website remotely with a web hosting company. (Granted, the WSAT"s files are available in the %WINDOWS%\Microsoft.NET\Framework\v2.0.50727\ASP.NETWebAdminFiles folder and can be deployed from there.)

Rather than move the existing WSAT tool to my remote host, I decided to build my own WSAT-like tool from the ground up. My version duplicates all features inside the Security section of the WSAT and adds a useful "Access Rules Summary" view of the website security as applied to any given user or role. The complete code can be downloaded from the end of this article and added to your site within a matter of minutes. This article provides an overview of my custom WSAT implementation and explores the user list and add and edit user pages in detail. A future article will explore the role management and access rules sections in detail. Read on to learn more!
Read More >

5/16/2007 Debugging SQL Server 2005 Stored Procedures in Visual Studio

With Microsoft SQL Server 2000 it was possible to debug stored procedures from directly within Query Analyzer (see Debugging a SQL Stored Procedure from inside SQL Server 2000 Query Analyzer for more information). With SQL Server 2005, however, this functionality was moved out of SQL Server Management Studio and into the Visual Studio IDE. Using this technique, it is possible to step into your stored procedures, one statement at a time, from within Visual Studio. It is also possible to set breakpoints within your stored procedures" statements and have these breakpoints hit when debugging your application.

All editions of SQL Server 2005 include debugging support (including the Express Edition). However, only the Team Systems and Professional editions of Visual Studio enable stored procedure debugging from within the IDE. In short, if you are using Visual Web Developer or Visual Studio Standard Edition then you cannot step through a stored procedure or enter the stored procedure via application debugging.

In this article we will examine how to debug SQL Server 2005 stored procedures through the Visual Studio IDE. We will look at both stepping into a stored procedure directly from the IDE as well as how to set breakpoints within the stored procedure that are then hit when debugging the application. Read on to learn more!
Read More >

5/9/2007 Deploying a Local Database to a Remote Web Host

Microsoft Visual Web Developer and SQL Server 2005 Express Edition make it easy to design, develop, and test ASP.NET web applications locally. In my books, tutorials, and classes, the explanations, examples, and assignments often use these tools to develop web applications locally. After creating a usable, interesting web application, readers and students invariably ask, "How do I get this website on the Internet?" Web applications designed for personal use, as a hobby, or for small- to medium-sized businesses are typically hosted by a web host provider. A web host provider is a company that has a plethora of computers that are accessible from the Internet. For a monthly fee, you can upload your web application to a web hosting company"s servers to make your site available.

Deploying a web application from your local development machine to the web host company"s servers requires uploading the files and information needed to serve your site. Many of these files can simply be uploaded to the web hosting company"s servers using FTP or FrontPage Server Extensions (FPSE). What is more challenging is uploading a Microsoft SQL Server database from the local development machine to the remote web host. This challenge stems in part from the fact that most web hosting companies disallow use of Microsoft SQL Server 2005 Express Edition and instead require that you use a database on their database server (which might be SQL Server 2000 or 2005). Therefore, to deploy your site you will need to somehow duplicate your database"s schema and data on the web hosting company"s database server.

In short, duplicating a database"s schema and data often means obtaining the T-SQL scripts to create the schema and add the data and executing that script on the remote database server. Fortunately, this process is greatly simplified by Microsoft"s SQL Server Database Publishing Wizard. This wizard allows you to create the script needed to publish a database directly from within Visual Studio. Read on to learn more!
Read More >

5/1/2007 Accessing and Updating Data in ASP.NET 2.0: Inserting Data
A Multipart Series on ASP.NET 2.0"s Data Source Controls
ASP.NET 2.0 introduced a number of new Web controls designed for accessing and modifying data. These controls allow page developers to declaratively access and modify data without writing any code to perform the data access. This article is one in a series of articles on ASP.NET 2.0"s new data source controls.

  • Data Source Control Basics - explores the concepts and advantages of data source controls, and compares their usage in ASP.NET 2.0 to data access techniques in ASP.NET 1.x.
  • Accessing Database Data - shows how to use the SqlDataSource and AccessDataSource controls to query data from a relational database.
  • Filtering Database Data with Parameters - learn how to retrieve just a subset of database data based on hard-coded values and values from the querystring, other Web controls on the page, session variables, and so on.
  • Retrieving XML Data with XmlDataSource Control - see how to retrieve both remote and local XML data and display it in a data Web control.
  • Creating Custom Parameter Controls - learn how to create your own custom, declarative Parameter controls for use in the data source controls" parameters collections.
  • Examining the Data Source Control"s Events - explore the events raised during a data source control"s lifecycle.
  • Declaratively Caching Data - learn how to cache data to the data cache simply by setting a couple of data source control properties.
  • Programmatically Accessing Data using the Data Source Controls - programmatically retrieve, insert, delete, and update data using the SqlDataSource and AccessDataSource controls.
  • Inserting Data - learn how to insert data using a SqlDataSource control. Also examines how to retrieve the IDENTITY column value for the just-inserted record.
  • (Subscribe to this Article Series! )

    ASP.NET 2.0"s data source and data Web controls make working with data much easier than in previous versions. These controls allow for a declarative approach to working with data, without needing to write any cumbersome data access code. The articles we have explored in the series thus far have focused on understanding the core concepts of the data source controls and how to retrieve data from the database. In addition to retrieving data, the data source controls can also insert, update, and delete data.

    In this article we will focus on using the SqlDataSource control to insert records into a database. We will look at three examples: using a SqlDataSource and to insert a record using values entered by the user through various TextBoxes, DropDownLists, and other Web controls on an ASP.NET page; inserting using a SqlDataSource and a DetailsView control; and determining the value of the just-inserted record"s IDENTITY column. Read on to learn more!
    Read More >

    4/25/2007 Maintaining a Log of Database Changes - Part 2

    In Part 1 of this two-part article series we looked at the motivation behind maintaining a log of database changes and compared and contrasted different techniques for persisting historical data to "history" tables. In addition to creating the table (or tables) to store the historical data, we also need to devise some mechanism to insert any changes to the "history" table(s) whenever data is inserted, updated, or deleted from a table whose history is being tracked.

    Triggers are designed to execute T-SQL in response to INSERT, UPDATE, and DELETE commands, and therefore are often used to add the historical data to the "history" tables. Alternatively, historical information can be manually recorded each time an insert, update, or delete is performed. This is most easily accomplished when using stored procedures to perform all data modifications.

    In this article we will discuss the pros and cons of using triggers and manual techniques for maintaining changes to a database table. We will also build trigger- and manual-based implementation from the ground up. Read on to learn more!
    Read More >

    4/18/2007 Accessing and Updating Data in ASP.NET 2.0: Programmatically Accessing Data using the Data Source Controls

    One of the benefits of using Source Code Control (SCC) software like SourceSafe, Perforce, Subversion, Vault, and others is that the software keeps a detailed history of all changes to the source code. With SCC, you can see how the code for a particular file has changed over time, and when and who made the changes. Moreover, with such a log in place it is easy to rollback the system to a previous state. A log that tracks changes to a system is sometimes referred to as an audit log, as it provides a repository of information that can be used to audit a system. In the case of SCC, your boss might want to perform an audit of the system to determine how a particular bug was introduced. By examining this log, your boss could determine who entered the buggy line of code and when, as well look at what the code looked like before the bug was introduced.

    The concept of an audit log can be extended to database data as well. With a little bit of effort it is possible to setup a system that records all inserts, updates, and deletes to a specified set of database "history" tables. By logging all changes to the underlying data, it is possible to determine how, exactly, the data in the database was modified over time, as well as who made the changes and when. Database audit logs are especially useful in scenarios where the correctness of the data is essential or when there are many users all working on the same underlying data. In some scenarios audit logs are required by law.

    In this article - the first of a two-part series - we will discuss different techniques for storing changes to database data and their advantages and disadvantages. If you have had first-hand experience implementing database audit logging, I invite your feedback, as I"d like to flesh out this article to include suggestions, anecdotes, and warnings from the community at large. Read on to learn more!
    Read More >

    4/11/2007 Accessing and Updating Data in ASP.NET 2.0: Programmatically Accessing Data using the Data Source Controls
    A Multipart Series on ASP.NET 2.0"s Data Source Controls
    ASP.NET 2.0 introduced a number of new Web controls designed for accessing and modifying data. These controls allow page developers to declaratively access and modify data without writing any code to perform the data access. This article is one in a series of articles on ASP.NET 2.0"s new data source controls.

  • Data Source Control Basics - explores the concepts and advantages of data source controls, and compares their usage in ASP.NET 2.0 to data access techniques in ASP.NET 1.x.
  • Accessing Database Data - shows how to use the SqlDataSource and AccessDataSource controls to query data from a relational database.
  • Filtering Database Data with Parameters - learn how to retrieve just a subset of database data based on hard-coded values and values from the querystring, other Web controls on the page, session variables, and so on.
  • Retrieving XML Data with XmlDataSource Control - see how to retrieve both remote and local XML data and display it in a data Web control.
  • Creating Custom Parameter Controls - learn how to create your own custom, declarative Parameter controls for use in the data source controls" parameters collections.
  • Examining the Data Source Control"s Events - explore the events raised during a data source control"s lifecycle.
  • Declaratively Caching Data - learn how to cache data to the data cache simply by setting a couple of data source control properties.
  • Programmatically Accessing Data using the Data Source Controls - programmatically retrieve, insert, delete, and update data using the SqlDataSource and AccessDataSource controls.
  • (Subscribe to this Article Series! )

    Working with data in ASP.NET version 1.x required writing data access code. This involved establishing a connection to the database, specifying the SQL command, and then executing the command. ASP.NET 2.0"s data source controls greatly simplifies this process by encapsulating the data access pattern within a Web control construct. As such, data can be retrieved or modified and bound to a Web control without writing a single line of code. We explored the essentials of declarative data binding earlier in this article series in the Data Source Control Basics and Accessing Database Data articles.

    In addition to being used declaratively, the data source Web controls can also be accessed programmatically. It is possible to add a SqlDataSource or AccessDataSource control to a web page, specify SELECT, INSERT, UPDATE, or DELETE queries, and then to programmatically execute one of the control"s SQL commands. Such an approach is useful when you need to work with data programmatically, but want to avoid having to write the boilerplate data access code. In short, using the data source controls in this manner allows for data to be accessed programmatically with a single line of code.

    In this article we will examine how to use the SqlDataSource control to programmatically retrieve, insert, and delete data. Read on to learn more!
    Read More >

    4/4/2007 Filtering Custom Paged Results

    The ASP.NET 2.0 data web controls - the GridView, DetailsView, and FormView - all provide built-in paging support that can be enabled at the tick of a checkbox. Unfortunately, this built-in paging support is very inefficient when paging through large amounts of data since it naively grabs all of the records from the data being paged through even though only a subset of the records are displayed. Consequently, when paging through several hundred or thousands of records, it behooves you to implement custom paging. With custom paging, the data Web control hands over its paging responsibilities to us, the page developer. We are tasked with efficiently grabbing the precise subset of records to display and providing this information to the data Web control.

    Previous articles here on 4Guys have looked at implementing custom paging in ASP.NET 2.0. In Custom Paging in ASP.NET 2.0 with SQL Server 2005 we looked at using a GridView, a Typed DataSets, an ObjectDataSource control, and SQL Server 2005"s new ROW_NUMBER() keyword to efficiently page through 50,000 records 10 at a time. Another article, Sorting Custom Paged Results, looked at a technique for efficiently sorting the custom paged results.

    In addition to paging and sorting, another common data request is filtering. When using the inefficient default paging, filtering is easy to implement but includes the same inherent inefficiencies: the data Web control retrieves all of the filtered records even though only a subset of them are displayed on each page. It is possible to implement filtering with custom paging and sorting, however. In this article we will look at extending the custom paging and sorting example - which currently pages and sorts through the 50,000 employees in a fictional company - to include the ability to filter the displayed employees by their department. Read on to learn more!

    Before tackling this article make sure you have read and worked through Custom Paging in ASP.NET 2.0 with SQL Server 2005 and Sorting Custom Paged Results...
    Read More >

    上一页 1 2 3 4 5 下一页

       

    Site List:
    >>Xbox Live_s Major Nelson
    >>Xbox 360 & SharePoint 2007 Weblog
    >>Carsten Keutmann_s Blog
    >>Mohamed Zaki_s Blog [Sharepoint MVP]
    >>The Mit_s Blog
    >>Mart Muller_s Sharepoint Weblog
    >>Microsoft SharePoint Products and Technologies Team Blog
    >>SharePoint Solutions Blog
    >>4GuysFromRolla.com Headlines
    >>ASP.NET Blogs
    >>SharePoint Blogs
    >>SharePoint Blogs
    >>Joel on Software
    >>ADO Guy_s Rants and Raves
    >>Microsoft Live Labs
    >>GadgetNews
    >>Windows Vista Team Blog
    >>VoIP & Gadgets Blog
    >>schrankmonster blog
    >>Via Virtual Earth Blog
    >>Feed
    >>MSDN Blogs
    >>Mashable!

    Links:
    Jack's Readings

    Month Archives:
    Oct 2007
    Sep 2007

    Top Tags:
    social software social networking .NET mashable Sharepoint ASP.NET Web 2.0 Web2.0 Startups Community News Search Marketplace General Software Development AJAX Windows Vista Visual Studio Microsoft myspace Silverlight People Powered! YouTube Vista MOSS Featured News C# Events MOSS 2007 Google WPF Office 2007 Web Community Security General Personal Xbox 360 facebook Tools development SharePoint 2007 Fun Atlas Architecture ASP.NET AJAX myspace codes TheLongTail IIS SQL Server Developers Revenue Sharing Video Pictures WCF Mobile 2.0 Announcements Orcas MIX07 Arcade Team System JavaScript News



    @2007 All rights Reserved