Вы находитесь на странице: 1из 66

XML MIGRATION

A Project Report Submitted to the

MADURAI KAMARAJ UNIVERSITY,MADURAI


In partial fulfillment of the requirement for the award of the degree of BACHELOR OF COMPUTER APPLICATION Submitted by V.VINOTHINI ( Reg.No:B0124532)
Under the guidance of

Mrs.S.DEVI.MSc.M.Pil.,(Ph.D) HEAD, DEPARTMENT OF BCA AND MSc(CS&IT)


N.P.R. ARTS & SCIENCE COLLEGE NATHAM

DEPARTMENT OF BCA AND MSc(CS&IT)


N.P.R. ARTS & SCIENCE COLLEGE NATHAM 2012-2013

BONAFIDE CERTIFICATE

This is to certify that the project entitled XML MIGRATION is the bonafide record work done by V.VINOTHINI (REG NO: B0124532)in partial fulfillment of the requirement for the award of the Degree of Bachelor of computer application during the year 2012-2013 and this project represents the original work of the candidates.

INTERNAL GUIDE

HEAD OF THE DEPT, DEPARTMENT OF BCA AND MSc(CS&IT)

Submitted for the viva voce examination held on________

INTERNAL EXAMINER

EXTERNAL EXAMINER

DECLARATION
I hereby declare that the project entitled XML MIGRATION is developed in N.P.R.ARTS AND SCIENCE COLLEGE, NATHAM.This project report is originally prepared by us and carried out under the guidance of Mrs.S.DEVI. M.Sc.,M.phil.,(Ph.D), N.P.R.ARTS AND SCIENCE COLLEGE, NATHAM for the partial fulfillment of Bachelor of Computer Application.

Place: Date: V.VINOTHINI (Reg.No:B0124532)

ACKNOWLEDGEMENT

First of all, I would like to thank God, the Almighty for having made everything possible by giving us strength and courage to do this work. I wish to take this opportunity to express my gratitude to our management for providing me with all kinds of facilities at right time for the completion of my project. sI wish to express my sincere thanks to our honorable principal Dr.P. Saravanan M.Sc.,M.Phil. M.A.,B.Ed ,Ph.D for providing me an opportunity to work on this project. Apart from the efforts of myself, the success of my project depends largely on the encouragement and guidelines of Mrs.S. Devi M.Sc.,M.Phil.,(Ph.D), Head Of the Department, Department of BCA &M.Sc. I take this opportunity to express my gratitude to my Head of the Department who have been instrumental in the successful completion of this project. I am highly indebted to my Class In charge Mrs. K. Imaya MSc.,M.Phil, Lecturer, Department of BCA & M.Sc for her guidance and constant supervision throughout this project. My profound gratitude and deep regards to my internal guide Miss.S.DEVI MSc.,MPhil, (Ph.D) Lecturer, Department of BCA & M.Sc for her exemplary guidance, monitoring and constant encouragement throughout the course of this project. The guidance given by her time to time shall carry me a long way in the journey of life on which I am about to embark. The entire faculty members of Department of BCA & M.Sc , my beloved friends and my parents are acknowledged for their support and professional opinion on my project.

V.VINOTHINI
(Reg.NO:B0124532)

1. INTRODUCTION
BASIC CONCEPT
Now days many internet access has been developed enormously so net service provider has to bare some memory management problem. Web site which cannot have control over it data which will enlarge day to day operation.Web service has no control over runtime environment data.

1.1OBJECTIVES
Nowadays internet and user has been grown enormously so web service provider who host and maintain the web site ,provide server space has to face huge memory requirement problem. This project to convert the existing Database like MS-Access into the script like file format.In web, database is widely used at present. The database occupies some part of memory in the server and amount should be paid to maintain the database. The amount will depend upon the database size, and also Access and Oracle databases are platform dependent. While using databases, lot of problems will be arise like database Administrator support, Data corruption, huge memory spaces, and unnecessary expenses for database security. This system is designed to eliminate the drawbacks of the existing system. It is designed by to script based storing and retrieving data ,script is platform independent

XML Introduction to XML


What is XML? XML is a markup language for structured documentation.Structured documents are documents that contain both content (words, pictures, etc.) and some indication of what role that content plays (for example, content in a section heading has a different meaning from content in a footnote, which means something different than content in a figure caption, etc.). Almost all documents have some structure.

A markup language is a mechanism to identify structures in a document. The XML specification defines a standard way of adding markup to documents. So XML is Just Like HTML?

No. In HTML, both the tag semantics and the tag set are fixed. An <h1> is always a first level heading and the tag <ati.product.code> is meaningless. The W3C, in conjunction with browser vendors and the WWW community, is constantly working to extend the definition of HTML to allow new tags to keep pace with changing technology and to bring variations in presentation (stylesheets) to the Web. However, these changes are always rigidly confined by what the browser vendors have implemented and by the fact that backward compatibility is paramount. And for people who want to disseminate information widely, this has to include more than just the latest releases of Netscape and Internet Explorer. XML specifies neither semantics nor a tag set. In fact XML is really a meta-language for describing markup languages. In other words, XML provides a facility to define tags and the structural relationships between them. Since there's no predefined tag set, there can't be any preconceived semantics. All of the semantics of an XML document will either be defined by the applications that process them or by stylesheets. So XML Is Just Like SGML? No. Well, yes, sort of. XML is defined as an application profile of SGML. SGML is the Standard Generalized Markup Language defined by ISO 8879. SGML has been the standard, vendorindependent way to maintain repositories of structured documentation for more than a decade, but it is not well suited to serving documents over the web (for a number of technical reasons beyond the scope of this article). Defining XML as an application profile of SGML means that any fully conformant SGML system will be able to read XML documents. However, using and understanding XML documents does not require a system that is capable of understanding the full generality of SGML. XML is a much-restricted form of SGML.

For technical purists, it's important to note that there may also be subtle differences between documents as understood by XML systems and those same documents as understood by SGML systems. In particular, treatment of white space immediately adjacent to tags may be different. Why XML? In order to appreciate XML, it is important to understand why it was created. XML was created so that richly structured documents could be used over the web. The only viable alternatives, HTML and SGML, are not practical for this purpose.HTML, as we've already discussed, comes bound with a set of semantics and does not provide arbitrary structure.SGML provides arbitrary structure, but is too difficult to implement just for a web browser. Full SGML systems solve large, complex problems that justify their expense. Viewing structured documents sent over the web rarely carries such justification.

This is not to say that XML can be expected to replace SGML. While XML is being designed to deliver structured content over the web, some of the very features it lacks to make this practical, make SGML a much more satisfactory solution for the creation and long-time storage of complex documents. In many organizations, filtering SGML to XML to serve it over the web will be standard procedure. XML Development Goals.It shall be straightforward to use XML over the Internet.Users must be able to view XML documents as quickly and easily as HTML documents. In practice, this will only be possible when XML browsers are as robust and widely available as HTML browsers, but the principle remains. XML shall support a wide variety of applications.XML should be beneficial to a wide variety of diverse applications: authoring, browsing, content analysis, etc. Although the initial focus is on serving structured documents over the web, it is not meant to narrowly define XML. XML shall be compatible with SGML.Most of the people involved in the XML effort come from organizations that have a large, in some cases staggering, amount of material in SGML. XML was designed pragmatically, to be compatible with existing standards such as SGML , while solving the relatively new problem of sending richly structured documents over the web.

It shall be easy to write programs that process XML documents.The colloquial way of expressing this goal is that it ought to take about two weeks for a competent computer science graduate student to build a program that can process XML documents. The number of optional features in XML is to be kept to an absolute minimum, ideally zero.Optional features inevitably raise compatibility problems when users want to share documents and sometimes lead to confusion and frustration. XML documents should be human-legible and reasonably clear.If you don't have an XML browser and you've received a hunk of XML from somewhere, you ought to be able to look at it in your favorite text editor and actually figure out what the content means. The XML design should be prepared quickly.Standards efforts are notoriously slow. XML is needed to solve problems that exist right now so time is of the essence. The design of XML shall be formal and concise.In many ways a corollary to rule 4, it essentially means that XML must be expressed in EBNF and must be amenable to modern compiler tools and techniques. There are a number of technical reasons why the SGML grammar cannot be expressed in EBNF. Writing a proper SGML parser requires handling a variety of rarely used and difficult to parse language features. XML does not.

XML documents shall be easy to create.Although there will eventually be sophisticated editors to create and edit XML content, they won't appear immediately. In the interim, it must be possible to create XML documents in other ways: directly in a text editor, with simple shell and Perl scripts, etc. Terseness in XML markup is of minimal importance.Several SGML language features were designed to minimize the amount of typing required to manually key in SGML documents. These features are not supported in XML. From an abstract point of view, these documents are indistinguishable from their more fully specified forms, but supporting these features adds a considerable burden to the SGML parser (or the person writing it, anyway). In addition, most

modern editors offer better facilities to define shortcuts when entering text. XML is a text-based markup language that is fast becoming the standard for data interchange on the web. As with HTML, you identify data using tags (identifiers enclosed in angle brackets: <...>). Collectively, the tags are known as markup. But unlike HTML, XML tags identify the data rather than specify how to display it. Whereas an HTML tag says something like, "Display this data in bold font" (<b>...</b>), an XML tag acts like a field name in your program. It puts a label on a piece of data that identifies it (for example, <message>...</message>).

Note: Because identifying the data gives you some sense of what it means (how to interpret it,
what you should do with it), XML is sometimes described as a mechanism for specifying the semantics (meaning) of the data.

In the same way that you define the field names for a data structure, you are free to use any XML tags that make sense for a given application. Naturally, for multiple applications to use the same XML data, they must agree on the tag names they intend to use. </message> Throughout this tutorial, we use boldface text to highlight things we want to bring to your attention. XML does not require anything to be in bold! The tags in this example identify the message as a whole, the destination and sender addresses, the subject, and the text of the message. As in HTML, the <to> tag has a matching end tag: </to>. The data between the tag and its matching end tag defines an element of the XML data. Note, too, that the content of the <to> tag is contained entirely within the scope of the <message>..</message> tag. It is this ability for one tag to contain others that lets XML represent hierarchical data structures. Again, as with HTML, whitespace is essentially irrelevant, so you can format the data for readability and yet still process it easily with a program. Unlike HTML, however, in XML

you can easily search a data set for messages containing, say, "cool" in the subject, because the XML tags identify the content of the data rather than specify its representation.

Tags and Attributes


Tags can also contain attributes--additional information included as part of the tag itself, within the tag's angle brackets. The following example shows an email message structure that uses attributes for the to, from, and subject fields: As in HTML, the attribute name is followed by an equal sign and the attribute value, and multiple attributes are separated by spaces. Unlike HTML, however, in XML commas between attributes are not ignored; if present, they generate an error. XMLMigration from ruby community is a great tool to make developer think about the migration from the beginning of the project, which is a right think to do. XML is probably the most popular data type used in java community, however, there is nothing can help developer to do XML migration.

The main feature of this project. Automatically backup the old XML Validate the old xml based on the old xsd before the processing started. Apply the new version XSD changes and migrate the old xml using XSLT. Validate the new xml based on the new xsd after the processing finished. Expose the XMLMigration bean as Spring bean.

2.SYSTEM REQUIREMENTS
2.1 Hardware Requirements Processor RAM Hard disk : : : Dual Core 2.8 ghz 512 MB 200 GB

2.2Software Requirements Operating System Languages Backend : : : Windows 2000/xp/2007 VB.NET SQL SERVER

3. SOFTWARE OVERVIEW
3.1 .NET Framework
Now that you are familiar with the major goals of the .NET Framework, let's briefly examine its architecture. As you can see in Figure 3.2, the .NET Framework sits on top of the operating system, which can be a few different flavors of Windows and consists of a number of components. . NET is essentially a system application that runs on Windows.

Fig: 3.1.1 .NET Framework Conceptually, the CLR and the JVM are similar in that they are both runtime infrastructures that abstract the underlying platform differences. However, while the JVM officially supports only the Java language, the CLR supports any language that can be represented in its Common Intermediate Language (CIL). The JVM executes byte code, so it can, in principle, support many languages, too. Unlike Java's byte code, though, CIL is never interpreted. Another conceptual difference between the two infrastructures is that Java code runs on any platform with a JVM, whereas .NET code runs only on platforms that support the CLR.

The Common Language Runtime


At the heart of the .NET Framework is the common language runtime. The common language runtime is responsible for providing the execution environment that code written in a .NET language runs under. The common language runtime can be compared to the Visual Basic 6 runtime, except that the common language runtime is designed to handle all .NET languages, not just one, as the Visual Basic 6 runtime did for Visual Basic 6. The following list describes some of the benefits the common language runtime gives you:

Automatic memory management Cross-language debugging Cross-language exception handling Full support for component versioning Access to legacy COM components XCOPY deployment Robust security model You might expect all those features, but this has never been possible using Microsoft

development tools. Figure 4.1.2 shows where the common language runtime fits into the .NET Framework.

Fig: 3.1.2 The common language runtime. Code written using a .NET language is known as managed code. Code that uses anything but the common language runtime is known as unmanaged code. The common language runtime provides a managed execution environment for .NET code, whereas the individual runtimes of non-.NET languages provide an unmanaged execution environment.

Inside the Common Language Runtime


The common language runtime enables code running in its execution environment to have features such as security, versioning, memory management and exception handling because of the way .NET code actually executes. When you compiled Visual Basic 6 forms applications, you had the ability to compile down to native node or p-code.

Fig: 3.1.3 Visual Basic 6 compiler options dialog.


When you compile your applications in .NET, you aren't creating anything in native code. When you compile in .NET, you're converting your codeno matter what .NET language you're usinginto an assembly made up of an intermediate language called Microsoft Intermediate Language. The file format for the IL is known as PE (portable executable) format, which is a standard format for processor-specific execution. When a user or another component executes your code, a process occur called just-in-time (JIT) compilation, and it's at this point that the IL is converted into the specific machine language of the processor it's executing on. This makes it very easy to port a .NET application to any type of operating system on any type of processor because the IL is simply waiting to be consumed by a JIT compiler.

When the IL code is JITted into machine-specific language, it does so on an as-needed basis. If your assembly is 10MB and the user is only using a fraction of that 10MB, only the required IL and its dependencies are compiled to machine language. This makes for a very efficient execution process. But during this execution, how does the common language runtime make sure that the IL is correct? Because the compiler for each language creates its own IL,

there must be a process that makes sure what's compiling won't corrupt the system. The process that validates the IL is known as verification. Figure 4.1.4 demonstrates the process the IL goes through before the code actually executes.

Fig: 3.1.4 The JIT process and verification


When code is JIT compiled, the common language runtime checks to make sure that the IL is correct. The rules that the common language runtime uses for verification are set forth in the Common Language Specification (CLS) and the Common Type System (CTS). The .NET Framework Class Library The second most important piece of the .NET Framework is the .NET Framework class library (FCL). As you've seen, the common language runtime handles the dirty work of actually running the code you write. But to write the code, you need a foundation of available classes to access the resources of the operating system, database server, or file server. The FCL is made up of a hierarchy of namespaces that expose classes, structures, interfaces, enumerations, and delegates that give you access to these resources.

The Structure of a .NET Application


To understand how the common language runtime manages code execution, you must examine the structure of a .NET application. The primary unit of a .NET application is the

assembly. An assembly is a self-describing collection of code, resources, and metadata. The assembly manifest contains information about what is contained within the assembly.

The assembly manifest provides:


Identity information, such as the assemblys name and version number A list of all types exposed by the assembly A list of other assemblies required by the assembly A list of code access security instructions, including permissions required by the assembly and permissions to be denied the assembly Each assembly has one and only one assembly manifest, and it contains all the description

information for the assembly. However, the assembly manifest can be contained in its own file or within one of the assemblys modules.

Compilation and Execution of a .NET Application


When you compile a .NET application, it is not compiled to binary machine code; rather, it is converted to IL. This is the form that your deployed application takesone or more assemblies consisting of executable files and DLL files in IL form. At least one of these assemblies will contain an executable file that has been designated as the entry point for the application. When execution of your program begins, the first assembly is loaded into memory. At this point, the common language runtime examines the assembly manifest and determines the requirements to run the program. It examines security permissions requested by the assembly and compares them with the systems security policy. If the systems security policy does not allow the requested permissions, the application will not run. If the application passes the systems security policy, the common language runtime executes the code. It creates a process for the application to run in and begins application execution. The .NET Framework base class library contains the base classes that provide many of the services and objects you need when writing your applications. The class library is organized into

namespaces. A namespace is a logical grouping of types that perform related functions. Namespaces are logical groupings of related classes. The namespaces in the .NET base class library are organized hierarchically. The root of the .NET Framework is the System namespace. Other namespaces can be accessed with the period operator. A typical namespace construction appears as follows:

System System.Data System.Data.SQLClient The first example refers to the System namespace. The second refers to the System.Data namespace. The third example refers to the System.Data.SQLClient namespace. Table 1.1 introduces some of the more commonly used .NET base class namespaces.

Introduction to Object-Oriented Programming


Programming in the .NET Framework environment is done with objects. Objects are programmatic constructs that represent packages of related data and functionality. Objects are self-contained and expose specific functionality to the rest of the application environment without detailing the inner workings of the object itself. Objects are created from a template called a class. The .NET base class library provides a set of classes from which you can create objects in your applications. You also can use the Microsoft Visual Studio programming environment to create your own classes. This lesson introduces you to the concepts associated with object-oriented programming.

Objects, Members, and Abstraction


An object is a programmatic construct that represents something. In the real world, objects are cars, bicycles, laptop computers, and so on. Each of these items exposes specific functionality and has specific properties. In your application, an object might be a form, a control such as a button, a database connection, or any of a number of other constructs. Each object is a complete functional unit, and contains all of the data and exposes all of the functionality required to fulfill its purpose. The ability of programmatic objects to represent real-world objects is called abstraction.

Classes Are Templates for Objects


Classes were discussed in Chapter 1 and represent user-defined reference types. Classes can be thought of as blueprints for objects: they define all of the members of an object, define the behavior of an object, and set initial values for data when appropriate. When a class is instantiated, an in-memory instance of that class is created. This instance is called an object. To review, a class is instantiated using the New (new) keyword as follows: Visual Basic .NET ' Declares a variable of the Widget type Dim myWidget As Widget ' Instantiates a new Widget object and assigns it to the myWidget ' variable myWidget = New Widget() When an instance of a class is created, a copy of the instance data defined by that class is created in memory and assigned to the reference variable. Individual instances of a class are independent of one another and represent separate programmatic constructs. There is generally no limit to how many copies of a single class can be instantiated at any time. To use a real-world analogy, if a car is an object, the plans for the car are the class. The plans can be used to make any number of cars, and changes to a single car do not, for the most part, affect any other cars.

Objects and Members


Objects are composed of members. Members are properties, fields, methods, and events, and they represent the data and functionality that comprise the object. Fields and properties represent data members of an object. Methods are actions the object can perform, and events are notifications an object receives from or sends to other objects when activity happens in the application.

Object Models

Simple objects might consist of only a few properties, methods, and perhaps an event or two. More complex objects might require numerous properties and methods and possibly even subordinate objects. Objects can contain and expose other objects as members. Similarly, every instance of the Form class contains and exposes a Controls collection that comprises all of the controls contained by the form. The object model defines the hierarchy of contained objects that form the structure of an object.

Encapsulation
Encapsulation is the concept that implementation of an object is independent of its interface. Put another way, an application interacts with an object through its interface, which consists of its public properties and methods. As long as this interface remains constant, the application can continue to interact with the component, even if implementation of the interface was completely rewritten between versions.

Polymorphism
Polymorphism is the ability of different classes to provide different implementations of the same public interfaces. In other words, polymorphism allows methods and properties of an object to be called without regard for the particular implementation of those members. There are two principal ways through which polymorphism can be provided: interface polymorphism and inheritance polymorphism.

Interface Polymorphism
An interface is a contract for behavior. Essentially, it defines the members a class should implement, but states nothing at all about the details of that implementation. An object can implement many different interfaces, and many diverse classes can implement the same interface. All objects implementing the same interface are capable of interacting with other objects through that interface.

Inheritance Polymorphism
Inheritance allows you to incorporate the functionality of a previously defined class into a new class and implement different members as needed. A class that inherits another class is said to derive from that class, or to inherit from that class. A class can directly inherit from only

one class, which is called the base class. The new class has the same members as the base class, and additional members can be added as needed. Additionally, the implementation of base members can be changed in the new class by overriding the base class implementation. Inherited classes retain all the characteristics of the base class and can interact with other objects as though they were instances of the base class.

Microsoft Visual Basic.Net


With its release for the .NET platform, the Visual Basic language has undergone dramatic changes. For example: 1. The language itself is now fully object-oriented. 2. Applications and components written in Visual Basic .NET have full access to the .NET Framework, an extensive class library that provides system and application services. 3. All applications developed using Visual Basic .NET run within a managed runtime environment, the .NET common language runtime.

3.2 Microsoft Office Access


The previously known as Microsoft Access, is a DBMS that combines the relational with a and software-development tools. It is a member of the suite of applications, included in the Professional and higher editions or sold separately. On May 12 2010, the current version of Microsoft Access 2010 was released by Microsoft in Office 2010; Microsoft Office Access 2007 was the prior version. MS Access stores data in its own format based on the Access Jet Database Engine. It can also import or link directly to stored in other applications and databases. It can use Microsoft Access to develop, and " can use it to build software applications. Like other, Access is supported by, an programming language that can reference a variety of objects including DAO (Data Access Objects), Data Objects, and many other ActiveX components. Visual objects used in forms and reports expose their methods and properties in the

VBA programming environment, and VBA code modules may declare and call Windows functions. 1992: Microsoft released Access version 1.0 on 13 November 1992, and an Access 1.1 release in May 1993 to improve compatibility with other Microsoft products and to include the Access Basic programming language. 1993: Microsoft specified the minimum hardware requirements for Access v2.0 as: Microsoft Windows v3.1 with 4 MB of required, 6 MB RAM recommended; 8 MB of available space required, 14 MB hard disk space recommended. The product shipped on seven 1.44 MB diskettes. The manual shows a 1993 copyright date.Originally, the software worked well with relatively small databases but testing showed that some circumstances caused. For example, file sizes over 10 MB proved problematic (note that most hard disks held less than 500 MB at the time this was in wide use), and the Getting Started manual warns about a number of circumstances where obsolete or incorrect configurations can cause. With the phasing out of Windows 95, 98 and ME, improved network reliability, and Microsoft having released 8 for the Jet, the reliability of Access databases has improved and it supports both more data and a larger number of users. With Office 95, Microsoft Access 7.0 (a.k.a "Access 95") became part of the Microsoft Office Professional Suite, joining Microsoft Excel, Word, and PowerPoint and transitioning from Access Basic to Visual Basic for Applications (VBA). Since then, Microsoft has released new versions of Microsoft Access with each release of Microsoft Office. This includes Access 97 (version 8.0), Access 2000 (version 9.0), Access 2002 (version 10.0), Access 2003 (version 11.5), Access 2007 (version 12.0), and Access 2010 (version 14.0).Versions 3.0 and 3.5 of database engine (used by Access 7.0 and the later-released Access 97 respectively) had a critical issue which made these versions of Access unusable on a computer with more than 1 GB of memory. While Microsoft fixed this problem for Jet 3.5/Access 97 post-release, it never fixed the issue with Jet 3.0/Access 95. The native Access database format (the Jet MDB Database) has also evolved over the years. Formats include Access 1.0, 1.1, 2.0, 7.0, 97, 2000, 2002, 2007, and 2010. The most significant transition was from the Access 97 to the Access 2000 format; which is not with earlier versions of Access. As of 2011 all newer versions of Access support the Access 2000 format. New features were added to the Access 2002 format which can be used by Access 2002, 2003, 2007, and 2010.MS Access 2007 introduced a new database format:. ACCDB supports complex such as multivalue and attachment fields. These new field types are essentially

recordsets in fields and allow the storage of multiple values in one field. With Access 2010, a new version of the ACCDB format supports hosting on a SharePoint 2010 server for exposure to the web.Prior to the introduction of Access, and Fox dominated the desktop database market. Microsoft Access was the first mass-market database program for Windows. With Microsoft's purchase of FoxPro in 1992 and the incorporation of Fox's Rushmore routines into Access, Microsoft Access quickly became the dominant database for Windows - effectively eliminating the competition which failed to transition from the world. Access's initial codename was Cirrus; the forms engine was called Ruby. This was before saw the prototypes and decided that the language component should be co-developed as a separate expandable application, a project called Thunder. The two projects were developed separately as the underlying forms engines were incompatible with each other; however, these were merged together again after. Access was also the name of a communications program from Microsoft, meant to compete with and other programs. This proved a failure and was dropped.

Networking
Based on the legacy system developed in the computer world, many networking program examples are in C codes that include the UNIX/Linux Socket. For Windows platform, before the .NET, network programming is based on the Winsock/Winsock2 that uses the C codes (standard C + Microsoft extension for C).

Winsock 1 is based on the Berkeley Socket. The Winsock2 codes contains the Win32 API. Winsock is still there, 'wrapped by' .NET framework with more features. It is obvious if you use classes from the System.Net.Sockets namespace. Take note that these tutorials are based on the Winsok2 and .NET APIs and not 'through' the Windows Driver Kits (WDK). There are many people searching the C++ codes for the Winsock programming on the Internet. To develop Windows GUI based networking using C++, you may need to learn and use the classes available in Microsoft Foundation Class (MFC) or find the latest MFC version in VS 2008 with 3.5 or latest framework. Other uses the third party C++ networking libraries/APIs. You may want to consider the C++ networking API/libraries, free and commercial that can be searched at C/C++ API/Libraries collections. Well, whatever name it is: the MFC/C++-CLI/VB .NET/C#/C, is nothing other than wrappers of the C sockets with extra 'features' too, and still based on the TCP/IP stack/OSI. However there is no reason for you not to use the .NET framework for the network programming for newer Windows platforms. At least, as shown in this tutorials, it is just for fun learning.

The C++ .NET in the 'latest version' of the .NET framework is based on the C+ +/CLI. At the end, the 'stable version', the Managed Extension for C++ => Managed C++ => C++ .NET => C++/CLI => another version ~> WCF. The C++/CLI is Microsoft extension to the standard C++ (2003). Other C++ codes for network programming might use the third party libraries or APIs such as Chilkat libraries and components Back to this site, it is a repository of code samples and examples for network programming using .NET framework based on the outdated version of the Network Programming for Microsoft Windows, 2nd Edition (here) and Network Programming for the Microsoft .NET Framework (this tutorial) by Anthony Jones, Jim Ohlund and Lance Olson. However, these tutorials try to concentrate more on the code examples part and the sample outputs (which are lacking in those books coupled with no updates and new editions).For the information part, you must refer to MSDN C/C++/VB .NET/C# because it is updated regularly making the info may outdated fast. This step-by-step tutorial with tons of screenshots and program examples output samples have been refined for better learning. All code has been recompiled using Visual Studio 2008 Express Edition (free)/Visual Studio 2008 Professional Edition (free for trial version) and using .NET framework 3.5. All the credit, copyright and related thingy must go to the original authors and publishers and please, don't forget to read the disclaimer, and privacy too. Most of the program examples also include the C++ .NET (C++/CLI huh?). The .NET framework used is 3.5 and all the obsolete classes/methods have been replaced by newer one. All the program examples include a step-by-step with sample outputs. Code samples dominated by C# and VB .NET. It is not just learning the network part of the .NET programming, by going through the step-by-step, you will also get familiar with the .NET programming as a general. You will learn on how to create and use the .NET classes, properties, defining and using new classes, calling methods/subroutines/functions, creating several type of projects such as class libraries (DLL), console mode applications, simple Windows forms (Windows GUI) and a very simple web applications. After some time of practising those tutorials, hopefully, you will get the impression that C# is closely 'similar' to C++ .NET. Hence, it should be 'easy' to convert the C# code to C++ .NET and vice versa.

Introduction
System.Net is the namespace in the Microsoft Windows .NET Framework that contains the core classes intended for building applications that communicate over a network. The types of functionality found in System.Net range from access to a raw socket to the ability to upload to and download from resources on the Internet. In addition to providing a languageindependent, object-oriented way to access network resources, System.Net serves as the communication infrastructure for higher-level, distributed application programming models such as XML-based Web services and .NET Remoting. Layers of System.Net The System.Net classes can be divided into four layers, as depicted in Figure 6-1 and described in the following list.

Figure 3.2.1: The layers of System.Net

1.

Basic network types and services: Fundamental types that are used for working
with Internet Protocol (IP) addresses or non-IP network addresses such as Internetwork Packet Exchange (IPX). This layer also includes classes for performing Domain Name System (DNS) resolution.

2.

Socket-level APIs: A set of managed classes for performing network communication


over a socket, such as sending and receiving data between two hosts.

3.

Application protocols: Classes intended to be used both on the client and on the middle

In this section, well walk through each layer and introduce the most commonly used classes for each layer. The layers will be covered in-depth in the following chapters.

Basic Network Types and Services


Figure 6-2 contains the classes that make up the basic types and services included in System.Net. In the subsequent sections, well look briefly at each of the basic types and services that are made accessible through System.Net. Although this section introduces the key types, most of them are covered in- depth in the chapters that follow.

Figure 6-2: Basic types and services provided by System.Net

Using IP Addresses
The IPAddress type provides a class representation of an IP address. It includes methods that can be used to perform common operations on an IP address, such as parsing the address. The following code shows how you would parse an IP address.

Visual Basic .NET


Sub ParseIPAddress(ByVal addressString As String) Try

Dim address As IPAddress address = IPAddress.Parse(addressString) Console.WriteLine("The address is " & address.ToString _ & " and is of the family " & _ address.AddressFamily.ToString + ".") Catch ex As Exception Console.WriteLine("Failure parsing" & addressString & _ ". " & ex.ToString) End Try End Sub Note that if an invalid IP address is specified in this case, IPAddress will throw a FormatException that should be handled by the application. The IPAddress class should be used for validation any time your application receives an IP address as input from a user, a configuration file, or another source. IPAddress also provides the ability to determine whether a particular address is a member of the Internet Protocol version 6 (IPv6) or the Internet Protocol version 4 (IPv4) address family. Finally, IPAddress contains a number of helper methods and fields, such as IPAddress.Any, IPAddress.IPv6Any, and IPAddress.IsLoopback. The Any fields can be used to indicate that the application should bind to a port that listens on all network interfaces of that address family. The IsLoopback method can be useful when validating whether a local loopback address is being used.

Working with Different Address Families


The System.Net.EndPoint class provides developers with a way to access resources through System.Net over protocols that belong to different address families that have different semantics at the addressing level . This functionality is useful when you need to write an application that talks over a non-IP protocol, such as AppleTalk, IPX, or infrared. Because IP-based protocols are the most commonly used on todays networks, System.Net includes an IPEndPoint type in the .NET Framework. In the case of IPEndPoint, an end point is defined as an IP address and a port number. The .NET Compact Framework includes an IrDAEndPoint implementation of the EndPoint class that can be used for communicating with other nodes using infrared technologies. In the case of an IrDAEndPoint, an end point is defined as a device ID and a service name. Although most developers will simply work within the confines of the IP address family, this extensibility point is useful because the definition of an end point often varies from one address family to another.

Accessing Protected Resources


System.Net defines an ICredential interface and an associated NetworkCredential class that provide a means of specifying network credentials, such as a user name and a password in cases where network authentication is required when accessing a resou rce. These classes are mainly used in the context of the HTTP application protocol classes. However, in newer release of the .NET Framework, their use is likely to be expanded to include other socket-level authentication scenarios as well. The following code demonstrates how you can use the NetworkCredential class to authenticate with a remote resource.

Visual Basic .NET


Sub RequestProtectedResource(ByVal resource As String) Console.WriteLine("Please enter your user name. ") Dim userName As String userName = Console.ReadLine() Console.WriteLine("Please enter your password. ")

Dim password As String password = Console.ReadLine() Dim client As New WebClient client.Credentials = New NetworkCredential(userName, password) client.DownloadFile(resource, "page.htm") End Sub

Notice that in this code the credentials are obtained by prompting the user to enter them on the command line. System.Net also provides a way of using the default credentials of the account under which the application is running. You do so by setting the Credentials property on a class equal to CredentialCache.DefaultCredentials. Whenever possible, developers should use default credentials instead of prompting the user or reading credentials from some other source because default credentials are obtained through the security systems integrated into the underlying operating system.

Accessing DNS
DNS can be used to represent nodes on the network with human-readable names rather than IP addresses. For example, imagine trying to remember a string of characters such as www.contoso.com instead of a series of numbers such as 207.168.24.30. One feature provided by DNS is the ability to have multiple IP addresses assigned to one host name. You can even have different IP address types (for example, IPv4 and IPv6) assigned to the same host. Its often useful to be able to resolve a name to the list of IP addresses associated with that name. Access to DNS is enabled and controlled in System.Net through the Dns, DnsPermission, and IPHostEntry classes. DNS is covered in more detail in Chapter 7. The following example shows the basic steps involved in resolving a name and outputting the corresponding IP addresses to the console using System.Net.

4.SYSTEM ANALYSIS

4.1 EXISTING SYSTEM:

Database is widely used at present. The database occupies some part of memory in the server and amount should be paid to maintain the database. The database require large server space.They use some of modern technique to manage data such as data compression ,data center and cluster but it lead to some disadvantage listed below Disadvantage of Existing System The compressed data can be loosed IT may cause damage to data while retrieving Not more security for data Cannot recover data loosed

4.2 PROPOSED SYSTEM:

The proposed tool is capable of converting database into multi platform script (xml).so user data can be accessed by user so fast and reliably. Xml has the nature of platform independent ,light weight and secure. Xml migration is a new technique to handle server space database more effectively .This technique can provide wide area for usage in server space. So each database used in server are migrated to xml on before uploading to server. Xml are demigrated to db while on usage ,while user access DB in their private space it will automatically convert from xml to db. XML's ubiquity and continually improving tool support has created a magnetism that attracts organizations everywhere. As organizations move to XML, they must also provide a coherent data migration strategy that allows their users to bring old files forward. This is a nontrivial problem that typically requires tedious code to implement the transformation process. Advantage of Proposed System

The proposed system is designed to eliminate the drawbacks of the existing system. It is used to convert the database into script and recover data from site. Script to DB and DB to script will reduce the data storage space. Script can be recover fastly from web service. Script are light weight Xml can easily carry data set and data table Xml support inbuilt data sets and user defined tags

4.3 FEASIBILITY STUDY Feasibility study has three aspects. They are 5.3.1 Technical Feasibility 5.3.2 Economic Feasibility 5.3.3 Operational Feasibility

4. 3. 1 Technical Feasibility
In Technical Feasibility, the following issues are taken into consideration.

Whether the required technology is available or not Whether the required resources are available. The resources considered here are Manpower, Software and Hardware. Our project had the required man power, software and hardware. Hence our project is technical feasible. Once the technical feasibility is established, it is important to consider the monetary factors also. Since it might happen that developing a particular project may be technically possible but it may require huge investments and benefits may be less. For evaluating this, economic feasibility of the proposed system is carried out.

4. 3. 2 Economic Feasibility
Economic Feasibility is the most frequently used method for evaluating the effectiveness of a system. There should be sufficient benefits in creating the system and the costs must be acceptable. Such a system is economically feasible. Our project is also economically feasible.

4. 3. 3 Operational Feasibility
Operational Feasibility is a measure of how well the solution of problems or a specific alternative solution will work in an organization. It is also a measure of how the people feel about the system. Operational Feasibility criteria measure the urgency of the problem or acceptability of a solution. Proposed systems are beneficial only if they turned into information system that will meet the organizations operating requirements. Operational feasibility is a consideration about the working of the system after installation in the company. Simply stated, this system asks if the system will work when it is developed and installed. Our project is operationally feasible.

5. PROJECT DESCRIPTION
5.1 MODULES DESCRIPTION Web service Monitoring
It is used to manage the multiple website by providing server space and other resource , this module is used to categories the web site according to user profile.

Data Conversion
The website often used was ranked and listed according to that user data was compressed for un often used data.

DB to script converter
The data which are not often used are converted into script while storing in server space which would be lightweight and easy to maintain

Script data Creation


This module is used to create the inputs through form as script for sending to client db which was converted into database at user end.

6.SYSTEM DESIGN

6.1 DATABASE DESIGN Table : User Table S.no 1 2 3 4 5 6 Field Name User Name Password Address Phone Mail id Datatype Text Text Text Text Number Text Size 25 25 25 30 10 10

6.2 DATA FLOW DIAGRAM

Level 0:

SOURCE DATABASE

XML MIGRATION

XML FILE

Level 1:
XML FILE DESIGNATION DATABASE

XML DEMIGRATION

7. SOFTWARE TESTING

7.1 TESTING INTRODUCTION:


After finishing the development of any computer based application, the next complicated time consuming process is testing. During the time of testing only the development company knows that, how far the user requirements have been met. The testing methods applied to our project are as follows. 7. 1 Unit Testing 7. 2 Integration Testing 7. 3 Validation Testing 7. 4 Output Testing 7. 5 Acceptance Testing

7.2 TESTING METHODOLOGY 7.2.1 UNIT TESTING:


In unit testing each module is tested individually. Xml migration must be validate because database are most valuable resources . So it should be validate on before migration and demigration.It focuses the verification efforts on the smallest unit of software in the module. This is known as module testing. In the project all the modules are tested separately. For our project testing is performed at programming stage itself. In this testing each module project is found to work satisfactorily with regard to the expected output from the module. There are some validations for fields. The unit testing is performed now and then whenever a patch is delivered for each module. This makes our project standard. Unit testing comprises the set of tests performed by an individual programmer

Prior to integration of the unit in to larger system. A program unit is usually small enough that the programmer who developed it can test it in a great detail. In unit testing the modules are independent of one another are tested, the test data for unit testing should follow each condition and option this testing helps to find out the errors in coding and option.

7.2.2 INTEGRATION TESTING:


Integration testing is the phase of software testing in which individual software modules are combined and tested as a group. In this project the parts of a module are tested first and then it will test some of its parts, integration testing is done successfully.

7.2.3 VALIDATION TESTING:


It begins after the integration testing is successfully assembled. Validation succeeds when the software functions in a manner that can be reasonably accepted by the client. In this project, the majority of the validation is done during the data entry operation where there is a maximum possibility of entering wrong data. Other validation will be performed in all process where correct details and data should be entered to get the required results.

7.2.4 OUTPUT TESTING:


After performing the validation testing, the next step is output testing of the proposed system since no application would be termed as useful until it produces the required output in the specified format.

7.2.5 ACCEPTANCE TESTING:


User Acceptance Testing is the key factor for the success of any application. The project under consideration is tested for user acceptance by constantly keeping in touch with perspective system users at the time of developing and making changes whenever required. All the above mentioned testing techniques are successfully completed by our project.

8.IMPLEMENTATION IMPLEMENTATION PHASE


Implementation refers to post-sales process of guiding a client from purchase to use of the software or hardware that was purchased. This includes Requirements Analysis, Scope Analysis, Customizations, Systems Integrations, User Policies, User Training and Delivery. These steps are often overseen by a Project Manager using Project Management Methodologies set forth in the Project Management Body of Knowledge. Software Implementations involve several professionals that are relatively new to the knowledge based economy such as Business Analysts, Technical Analysts, Solutions Architect, and Project Managers. The implementation is the final and important phase. It involves User training, system testing and successful running of the developed system. The users test the developed system when changes are made according to the needs. The testing phase involves the testing of the developed system using various kinds of data. An elaborate testing of data is prepared and system is tested using the tests data. Implementation is the stage where theoretical design turned into a working system. Implementation is planed carefully to propose system to avoid unanticipated problems. Many preparations involved before and during the implementation of proposed system. The system needed to be plugged in to the organizations network then it could be accessed from anywhere, after a user logins into the portal. The tasks that had to be done to implement the system were to create the database tables in the organization database domain. Then the administrator was granted his role so that the system could be accessed.

The next phase in the implementation was to educate the system. A demonstration of all the functions that can be carried out by the system was given to examination department person, who will make extensive use of the system.

Technical analysis
In finance, technical analysis is security analysis discipline for forecasting the direction of prices through the study of past market data, primarily price and volume. [1] Behavioral economics and quantitative analysis build on and incorporate many of the same tools of technical analysis
[2] [3][4] [5]

, which, being an aspect of active management, stands in

contradiction to much of modern portfolio theory. The efficacy of both technical and fundamental analysis is disputed by efficient-market hypothesis which states that stock market prices are essentially unpredictable.

Social Analysis
The role title has a wider meaning in relation to solving problems, but is more often used in the narrower domain of Technical architecture - the context for the remainder of this definition. In this context, the Solutions Architect is a very experienced architect with crossdomain, cross-functional and cross-industry expertise. He/she outlines solution architecture descriptions, then monitors and governs their implementation.

CODING:
Imports Microsoft.VisualBasic.Strings Imports Microsoft.VisualBasic.Conversion Imports System.Data.OleDb Imports System.IO Public Class Form1 Dim cmdXML As OleDbCommand Dim DScmdXML As OleDbDataAdapter Dim connect As OleDbConnection Dim fs As FileStream Dim sw As StreamReader Public Sql As SQLDataBase Public s, seltable As String Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim DSXML As New DataSet() Dim sqlXML As String Dim i, j As Integer Dim strPCode As String = "" Dim arrpcode As System.Array Dim xmlSW As System.IO.StreamWriter 'For i = 0 To ListBox1.Items.Count - 1 ' ' ' ' ' ' ' 'If ListBox1.Items(i).Selected Then If strPCode = "" Then strPCode = ListBox1.Items(i).Text Else strPCode = strPCode + "," + ListBox1.Items(i).Text End If 'End If

'Next 'arrpcode = strPCode.ToString.Split(",") MsgBox("tablename" + seltable) Try sqlXML = "Select * from " & seltable cmdXML = New OleDbCommand(sqlXML, connect) DScmdXML = New OleDbDataAdapter(cmdXML) DScmdXML.Fill(DSXML, seltable) 'MsgBox("<font face=verdana size=1>" & "Successfully Converted Table " & arrpcode(j) & " to Product.xml" & "</font>") Dim s As String = TextBox1.Text & seltable & ".xml" DSXML.WriteXml(s, XmlWriteMode.WriteSchema) Dim xmlSW2 As System.IO.StreamWriter = New System.IO.StreamWriter(TextBox1.Text & seltable & ".xml") DSXML.WriteXml(xmlSW2, XmlWriteMode.WriteSchema) xmlSW2.Flush() xmlSW2.Close() Catch ex As Exception MsgBox(ex.Message) End Try MsgBox("path=" & s) RichTextBox1.LoadFile(TextBox1.Text RichTextBoxStreamType.PlainText) End Sub Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Sql = New SQLDataBase Sql.Load() connect = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & s) connect.Open() & seltable & ".xml",

End Sub Private Sub OpenFileDialog1_FileOk(ByVal sender As System.Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles OpenFileDialog1.FileOk End Sub Private Sub TextBox1_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) End Sub Private Sub ListBox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ListBox1.SelectedIndexChanged seltable = ListBox1.Text End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Me.Hide() Form4.Show() End Sub End Class Imports System.Data.OleDb Public Class Form2 Private FileName As String Private ds As New DataSet() Dim con As OleDbConnection Dim cmd As OleDbCommand Dim rs As OleDbDataAdapter Dim dTable As DataTable Dim bSource As BindingSource Public i, ln As Integer Dim Str As String Dim ch As Char Public prov, dbs, query, ConnectionString, paths, a, b, c As String

Public Sql As SQLDataBase Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click 'Configure the openfile dialog prov = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" If OpenFileDialog1.ShowDialog <> Windows.Forms.DialogResult.Cancel Then dbs = OpenFileDialog1.FileName End If getAllTableNames() For i = 0 To dbs.Length - 1 ch = dbs(i) paths = paths + ch If ch = "\" Then paths = "" End If Next ln = paths.Length Str = LSet(dbs, dbs.Length - ln) End Sub Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Form1.ListBox1.Items.Add(ListBox1.Text) Me.Hide() Form1.s = dbs Form1.TextBox1.Text = Str Form1.Show() Sql.SqlCommand = New OleDbCommand("insert into TableData values('" & ListBox1.Text & "','" & Label5.Text & "','" & Str & "','" & dbs & "')", Sql.SqlDb) Sql.SqlCommand.ExecuteNonQuery() End Sub Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Sql = New SQLDataBase Sql.Load()

End Sub Public Sub getAllTableNames() Dim com As New OleDbCommand Dim con As OleDbConnection Dim i As Integer 'Give your database path ConnectionString = prov + dbs con = New OleDb.OleDbConnection(ConnectionString) con.Open() com.Connection = con Dim dtable As DataTable Try dtable = con.GetOleDbSchemaTable(OleDb.OleDbSchemaGuid.Tables, New Object() {Nothing, Nothing, Nothing, "TABLE"}) 'Table_Catalog,table_Schema,table_name,table_type For i = 0 To dtable.Rows.Count - 1 ListBox1.Items.Add(dtable.Rows(i).Item(2).ToString) Next Catch ex As Exception End Try End Sub Private Sub ListBox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ListBox1.SelectedIndexChanged con = New OleDbConnection(prov + dbs) query = "select * from " + ListBox1.Text

rs = New OleDbDataAdapter(query, con) dTable = New DataTable() rs.Fill(dTable) bSource = New BindingSource bSource.DataSource = dTable DataGridView1.DataSource = bSource rs.Update(dTable) End Sub Private Sub DataGridView1_CellContentClick(ByVal sender As System.Object, ByVal e As System.Windows.Forms.DataGridViewCellEventArgs) DataGridView1.CellContentClick End Sub End Class Imports System.Data.OleDb Public Class Form3 Public Sql As SQLDataBase Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click Sql.SqlCommand = New OleDbCommand("insert into user_sql values('" & TextBox3.Text & "','" & TextBox4.Text & "','" & TextBox5.Text & "','" & TextBox6.Text & "','" & TextBox7.Text & "','" & TextBox8.Text & "')", Sql.SqlConnection) Sql.SqlCommand.ExecuteNonQuery() MsgBox("User Created") End Sub Sub textclear() TextBox1.Text = "" TextBox2.Text = "" TextBox3.Text = "" Handles

TextBox4.Text = "" TextBox5.Text = "" TextBox6.Text = "" TextBox7.Text = "" TextBox8.Text = "" TextBox9.Text = "" End Sub Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click End Sub Private Sub Form3_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Sql = New SQLDataBase Sql.Sql_Connection() End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Sql.SqlCommand = New OleDbCommand("select * from user_sql ", Sql.SqlConnection) Sql.SqlDataReader = Sql.SqlCommand.ExecuteReader While Sql.SqlDataReader.Read If TextBox1.Text = Sql.SqlDataReader.GetValue(1) And TextBox2.Text = Sql.SqlDataReader.GetValue(2) Then Me.Hide() Form4.Show() Form4.Label2.Text = TextBox1.Text Exit While End If

End While End Sub End Class Public Class Form4 Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click Form6.Show() Me.Hide() End Sub Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Form5.Show() Form5.Label8.Text = Label2.Text Me.Hide() End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Form7.Show() Form7.Label3.Text = Label2.Text End Sub Private Sub Form4_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Dim S As SQLDataBase S = New SQLDataBase S.Load()

End Sub End Class Public Class Form5 Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click Form2.Show() Form2.Label5.Text = Label8.Text End Sub End Class Imports System.Data.OleDb Public Class Form6 Public Sql As SQLDataBase Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click Form4.Show() Me.Hide() End Sub Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click Sql.SqlCommand = New OleDbCommand("delete * from user_sql ", Sql.SqlConnection) Sql.SqlCommand.ExecuteNonQuery() End Sub Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click Sql.SqlCommand = New OleDbCommand("select * from user_sql ", Sql.SqlConnection)

Sql.SqlDataReader = Sql.SqlCommand.ExecuteReader While Sql.SqlDataReader.Read If TextBox4.Text = Sql.SqlDataReader.GetValue(0) Then TextBox4.Text = Sql.SqlDataReader.GetValue(1) TextBox5.Text = Sql.SqlDataReader.GetValue(2) TextBox6.Text = Sql.SqlDataReader.GetValue(3) TextBox7.Text = Sql.SqlDataReader.GetValue(4) TextBox8.Text = Sql.SqlDataReader.GetValue(5) End If End While End Sub Private Sub Form6_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Sql = New SQLDataBase Sql.Sql_Connection() End Sub Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Sql.SqlCommand = New OleDbCommand("update user_sql set unam='" & TextBox3.Text & "',pas='" & TextBox5.Text & "',add='" & TextBox6.Text & "',phn='" & TextBox7.Text & "',maid='" & TextBox8.Text & "')", Sql.SqlConnection) Sql.SqlCommand.ExecuteNonQuery() End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click TextBox3.Text = ""

TextBox4.Text = "" TextBox5.Text = "" TextBox6.Text = "" TextBox7.Text = "" TextBox8.Text = "" End Sub Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click Me.Hide() Form5.Show() End Sub End Class Imports System.Data.OleDb Public Class Form7 Dim con As OleDbConnection Dim cmd As OleDbCommand Dim rs As OleDbDataAdapter Dim dTable As DataTable Dim bSource As BindingSource Dim query As String Dim Sqldbs As SQLDataBase Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click Sqldbs.SqlCommand = New OleDbCommand("select * from TableData", Sqldbs.SqlDb) Sqldbs.SqlDataReader = Sqldbs.SqlCommand.ExecuteReader() While Sqldbs.SqlDataReader.Read If Sqldbs.SqlDataReader.GetValue(1) = Label3.Text Then ListBox1.Items.Add(Sqldbs.SqlDataReader.GetValue(0)) End If

End While End Sub Private Sub Form7_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Sqldbs = New SQLDataBase Sqldbs.Load() End Sub Private Sub ListBox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ListBox1.SelectedIndexChanged Sqldbs.SqlCommand = New OleDbCommand("select * from TableData", Sqldbs.SqlDb) Sqldbs.SqlDataReader = Sqldbs.SqlCommand.ExecuteReader() While Sqldbs.SqlDataReader.Read If ListBox1.Text = Sqldbs.SqlDataReader.GetValue(0) Then con = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + Sqldbs.SqlDataReader.GetValue(3)) End If End While query = "select * from " + ListBox1.Text rs = New OleDbDataAdapter(query, con) dTable = New DataTable() rs.Fill(dTable) bSource = New BindingSource bSource.DataSource = dTable DataGridView1.DataSource = bSource rs.Update(dTable)

End Sub End Class

9. CONCLUSION
Thus project has successfully convert and recover database on before server hosting. So the tool successfully convert into light weight DB. Xml migration is a secure and efficient manner it can convert recover data without any damage and data loss. Xml successfully light weight data manager system for web based database user and data hoster.

10. FUTURE ENHANCEMENT

This tool can be made as web based tool for website data host ,It can be made as add on tool for any browser of server based tool. Computer user widely uses browser then any other software tool . so it made as web browser add on for common use and advance.

Вам также может понравиться