Read an Excerpt
IntroductionIntroductionWelcome to Visual C# .NET 2003
Today, people are living in a busy time. Gone are the days when it took two to three weeks to get a decision on a credit application for a car. We live in a time where we need what we want, and we want what we need, right now.
Wanting information right now is a common theme in today's environment. Having it right now is today's challenge. Whether it's while driving in the car, flying in an airplane, working, or while watching television at home, we all want it now. To solve this dilemma, IBM introduced the world to personal computers. For a time this was great, but personal computers were too expensive for the average person to have at home, so other companies introduced the portable computer. Don't let the term portable confuse you, this computer was everything but portable. The portable computer eventually became small enough to actually carry around and everything seemed right with the world, at least for a time. However, as time passed, so did the fad of starting up your laptop to find the phone number or address of the person you were trying to contact. So, along came mobile devices. With time, mobile devices such as personal digital assistants (PDAs), cellular phones, and cellular phones that thought they were PDAs became more advanced and brought us to the brink of having everything that we wanted at our fingertips...but not quite.
The great thing about the world is that everyone has his own ideas. Some ideas are great, and some...well, some are not so great. The problem with this is that most people have a bias toward their own ideas and think that their way is the rightway. This causes companies to develop technologies to handle tasks in their own image and makes communication between similar devices, made by different manufacturers, difficult if not impossible. Imagine this: You are tasked with gathering stock prices from different vendors of stock quotes. One source requires that you query its database with a proprietary protocol. Another has a file that is reproduced every minute and requires you to download it and parse the file for all the information that is needed. And finally, the third source does not have a published interface and therefore requires that you perform screen scraping to produce the information required. Without the presence of a standard method of accessing the information, retrieving the required data is, at the very least, complicated.Along Came .NET
Fortunately, our friends in Redmond thought about this problem for quite a while and came up with a solution they call .NET. Microsoft took the time necessary to come up with an end-to-end solution for such areas as cross-language interoperability, runtime management of system stability, web services that use a standard protocol such as SOAP (Simple Object Access Protocol), and seamless communication of distributed components, just to name a few.
In writing this book, we have first and foremost tried to give you the information necessary to understand the technology and be able to apply this knowledge to your future projects. Secondly, we want you to understand not only how it works, but also why it works. Too many programmers today are content with knowing that making a call to function A will cause the system to perform a certain task. That's fine, but if you don't know how function A performs the task, how are you going to know why or if it breaks function B when used in a certain context? If you don't know how it works, you won't know how you can make your code faster, more efficient, more scalable, and more reliable. This book will take you into the internals of the .NET Framework. You will learn not only how to use attributes in C#, you'll also learn what they actually do, so that if something breaks, you will have a little insight into the framework to help you quantify the issue and quickly create a solution.What's New in Visual Studio .NET
The first time you open Visual Studio .NET, you will notice that there have been many changes from previous versions. Visual Studio .NET and the .NET Framework will change the way you view and create software. Some of the differences between Visual Studio .NET and its predecessors like Visual C++ 6.0 include
Redesigned user interface: The Visual Studio .NET user interface is a combination of the best features found in the previous versions of Visual C++, Visual Basic, and Visual InterDev.
Advanced Help system: Help is literally at your fingertips. With the new Dynamic Help system, links to help documentation are context aware; that is, they are displayed based on what you are currently working on. Also, Microsoft Developers Network (MSDN) is now incorporated into the integrated development environment (IDE) without having to use an external help application.
Vastly improved debugger: By incorporating multiple languages into Visual Studio .NET, they support cross-language debugging. You now have the ability to easily step from Visual Basic .NET to Visual C# code.
Deployment support: Visual Studio .NET now contains the necessary toolset to deploy your finished application to its final destination. Using Microsoft Installer technology, you can create merge modules or entire installations within the Visual Studio .NET IDE.
Automatic code documentation: By using a combination of Extensible Markup Language (
.NET: .NET is a technology that can't really be summed up in one succinct phrase. Needless to say, .NET is more than just a framework. Included within the .NET umbrella are such things as Windows Forms, web services and, of course, the new Microsoft programming language, C#.
The changes that come with Visual Studio .NET are enormous. Trying to understand all of these changes can seem overwhelming. However, upon completion of this book, you will know how, and be able to use all the features of the .NET Framework. If you need to create several objects that must communicate with each other across process or even the Internet, you will apply what you learn in Chapter 39, "Remoting." If you need to create an object that can persist itself after the program has terminated, you will use the knowledge from Chapter 7, "File and Stream I/O and Object Persistence." In all, you will benefit from the beginning from informed design decisions.
© Copyright Pearson Education. All rights reserved.