Comments
litl_phil wrote: While it's nice that Google and Acer share the vision of cloud-based computing, it's also worth noting that we at litl already have a webbook on the market (available at litl.com) that runs our own cloud-based OS. Unlike Chrome, litlOS is focused on creating a new and better web experience for the home, so we don't have the usual browser interface, we have our own innovative UI. In conjunction with easel mode (litl's inverted-V position) and our growing cohort of litl channels (special apps t...
Cloud Expo on Google News


2008 West
DIAMOND SPONSOR:
Data Direct
SOA, WOA and Cloud Computing: The New Frontier for Data Services
PLATINUM SPONSORS:
Red Hat
The Opening of Virtualization
GOLD SPONSORS:
Appsense
User Environment Management – The Third Layer of the Desktop
Cordys
Cloud Computing for Business Agility
EMC
CMIS: A Multi-Vendor Proposal for a Service-Based Content Management Interoperability Standard
Freedom OSS
Practical SOA” Max Yankelevich
Intel
Architecting an Enterprise Service Router (ESR) – A Cost-Effective Way to Scale SOA Across the Enterprise
Sensedia
Return on Assests: Bringing Visibility to your SOA Strategy
Symantec
Managing Hybrid Endpoint Environments
VMWare
Game-Changing Technology for Enterprise Clouds and Applications
Click For 2008 West
Event Webcasts

2008 West
PLATINUM SPONSORS:
Appcelerator
Get ‘Rich’ Quick: Rapid Prototyping for RIA with ZERO Server Code
Keynote Systems
Designing for and Managing Performance in the New Frontier of Rich Internet Applications
GOLD SPONSORS:
ICEsoft
How Can AJAX Improve Homeland Security?
Isomorphic
Beyond Widgets: What a RIA Platform Should Offer
Oracle
REAs: Rich Enterprise Applications
Click For 2008 Event Webcasts
SYS-CON.TV
Top Links You Must Click On


Bring Windows to the Web: Bringing Desktop Apps to Your Web Sites
As .NET 2.0 approaches, which new technologies are worth implementing?

Since the introduction of CGI in 1993, the Web has become an increasingly popular medium for interactive content and application development. The evolution of Web programming has come a long way in 12 years, and new technologies are being introduced on an almost daily basis. As a developer, it can be difficult to determine which new technologies are worth implementing and which should just be left alone.

New technologies afford us new opportunities to make better, more powerful Web applications. The demand for more functionality on Web sites is becoming greater and users now expect Web applications to run more like desktop applications. Web users are becoming dissatisfied with sites that just present a mass of information for them to browse through. They want to have searching, ability to provide feedback, and rating systems. They want ways to interact with the Web; they don't want to just be passive observers.

These new technologies can also help developers become more efficient. Faced with the challenge of reduced IT budgets, smaller teams, and compressed schedules to roll out new Internet and intranet sites and rich Web applications, developers need every advantage tilted in their favor to help their organizational Web strategies succeed. By leveraging the potential of the .NET framework, developers can both improve Web application functionality and take advantage of its object-oriented architecture to streamline and accelerate the development process. This article explains three key features of ASP.NET that you can implement to improve your development team's Web strategy.

Web Sites vs. Web Apps
Developers are quick to use the term Web application to describe just about any project they put on the Web. A Web site isn't a Web application just because it has some dynamic content or a few basic scripts; the term "application" implies a certain amount of interactivity. For example, many news sites contain huge amounts of dynamic information, but they often lack the interaction necessary to consider them Web applications. The content on the site may be managed with a Web app, but the user really doesn't notice any difference between a site with manually added information and one with a content management system. To become an application, it needs to be more than just a collection of static files.

The news site could become a Web application with some additions. Add some searching and indexing features, allow users to create personalized home pages, or create a system for them to give feedback and the site begins to become an application. Users want Web applications that function like their desktop applications. We now have the technology to add these interactive features that people expect from the sites they visit.

The .NET framework allows Web developers to bring many of these desktop application elements into their Web sites. Many might argue that ASP, PHP, and other Web scripting languages can offer the same functionality, but ASP.NET provides not only a more powerful object-oriented environment, but it also helps developers to work more efficiently. Web services also help .NET connect with other Web and desktop applications.

Using Visual Studio .NET
There is a wide variety of Web development applications in use today that range from simple text editors to full featured WYSIWYG applications such as DreamWeaver. Chances are if you're not already creating ASP.NET sites, you're not using Visual Studio .NET. However, Visual Studio offers a lot of features that will make developing in ASP.NET much easier.

The first and most obvious advantage of developing in Visual Studio over DreamWeaver or another WYSIWYG is the built-in compiler. When developing in Visual Studio you can build the entire project with a few shortcut keys, whereas in most other applications you have to use an external compiler, which can be a nightmare when debugging. Visual Studio also has code hinting and drag-and-drop functionality for server controls, which definitely help speed things up.

One downside to Visual Studio is its limited WYSIWYG functionality. Visual Studio was built to be a .NET IDE, not a Web design application, so in comparison to Hot Metal and DreamWeaver it's pretty awkward for writing HTML. If you do a significant amount of design or HTML coding, you will likely want to do the majority of your HTML and JavaScript work in whatever application you're currently using for design and use Visual Studio to program.

Developing with Server Controls
If you're familiar with VB.NET or C#, you're probably already familiar with most of the server controls you see in ASP.NET. Server controls are a great feature of ASP.NET because they help reduce code volume and make development a lot more efficient if used well. These controls incorporate both visual and functional elements that are common in Web development such as form elements and validation functions. You can also combine or modify preexisting controls into reusable custom controls.

Let's go over a brief example of a simple Web form with some server controls in it. There are a few things you should notice about the page overall. All of the server controls have the runat="server" attribute; this is required for any elements that will be used by ASP.NET. Each of the controls also needs a unique ID that allows you to reference the control with VB or C#.

The form in Listing 1 has three server controls and two sub routines to handle events from the server controls. Line 17 is a label server control that outputs a span tag that can be used to display messages to the browser.

Line 18 contains a text box control. The text box control outputs a text input to the browser and incorporates some great functionality that would normally require a fair amount of JavaScript. The OnTextChanged attribute assigns an event handler to be run when the text in the text input changes. The AutoPostBack attribute causes the form to automatically post when changes are made. These two attributes allow you to detect if text has been changed and automatically run the appropriate event handler with only one line of code. Line 19 contains a list box control that has very similar attributes to the text box control. Again, the control detects when a change has been made and automatically posts to the server and runs the appropriate event handler.

Now let's take a quick look at the event handlers. You'll notice that the text property is referenced on all three of the server controls - on line 6 for the text box and label controls, and on line 10 for the list box control. The built-in server controls often share these common properties, thereby making it very easy to exchange one for another. For example, changing a radio button to a check box would require only one line of code to be changed.

User Controls
User controls are files that can contain both visual and functional elements and can be used just like the built-server controls. They allow you to combine existing server controls, HTML, and VB or C# code into a reusable control. Some common user controls include login forms, calculators, or display elements. Let's look at an example user control and how it is implemented in the site.

About Bill Rogers
Bill Rogers is founder and CEO of Ektron, Inc (www.ektron.com). Founded in 1998, Ektron has nearly 15,000 customer integrations worldwide.

In order to post a comment you need to be registered and logged in.

Register | Sign-in

Reader Feedback: Page 1 of 1

Enterprise Open Source Magazine Latest Stories . . .
Oracle seems to have divided the open source ranks over the MySQL delay it’s having closing its acquisition of Sun. Eben Moglin, the GPL’s most ardent defender and delineator, the lawyer who has worked hand in glove for years with the Free Software Foundation’s founder Richard Stallman...
Cloud computing is a game changer. The cloud is disrupting traditional software and hardware business models by disrupting how IT service gets delivered. Entrepreneurial opportunities abound as this classic disruptive technology begins to proliferate, so it is no surprise that SYS-CON'...
The irony is that Oracle has advanced MySQL, lost money in the process, and helped its competitors - all at the same time. When Oracle buys Sun and controls MySQL the gift (other than to Microsoft SQL Server) keeps on giving as the existential threat to RDBs is managed by Redwood Shore...
WSO2, the open source SOA company, today announced the launch of the WSO2 Cloud Platform. Available today, the new WSO2 Cloud Platform features a family of WSO2 Cloud Virtual Machines; WSO2 Cloud Connectors for enabling fast, secure cloud services; and the multi-tenant WSO2 Governance-...
Now, the open source Mozilla Thunderbird client software can be used with Open-Xchange collaboration software. The "Community OXtender for Thunderbird" software connector gives users full access to appointments and contacts stored in the Open-Xchange Server and enables them to use Thun...
Morph Labs, a leading provider of enterprise cloud computing technology, today announced an introductory trial of the Morph CloudServer, an open, standards-based server IT organizations can use to rapidly model and evaluate their cloud implementations. A miniature "Cloud Environment in...
Subscribe to the World's Most Powerful Newsletters
Subscribe to Our Rss Feeds & Get Your SYS-CON News Live!
Click to Add our RSS Feeds to the Service of Your Choice:
Google Reader or Homepage Add to My Yahoo! Subscribe with Bloglines Subscribe in NewsGator Online
myFeedster Add to My AOL Subscribe in Rojo Add 'Hugg' to Newsburst from CNET News.com Kinja Digest View Additional SYS-CON Feeds
Publish Your Article! Please send it to editorial(at)sys-con.com!

Advertise on this site! Contact advertising(at)sys-con.com! 201 802-3021


SYS-CON Featured Whitepapers
ADS BY GOOGLE