• CREATE TABLE IF NOT EXISTS `student` ( • `SID` int (100) NOT NULL AUTO_INCREMENT, • ` Name ` varchar (100) NOT NULL, • `Address` varchar (500) NOT NULL, • `Email` varchar (100) NOT NULL, • `Mobile` varchar (25) NOT NULL, • PRIMARY KEY (`SID`) • ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=31; Open your instance of Visual Studio 2012, and create a new ASP.NET Web application. Name the project “MYSQLCRUDApplication ', as shown in the following figure: In the code behind file (Student.aspx.cs) write the code as in the following. • <%@ Page Title= ' Language= 'C#' MasterPageFile= '~/Site.Master' AutoEventWireup= 'true' • CodeBehind= 'Student.aspx.cs' Inherits= 'MYSQLCRUDApplication.Student'%> • • • Simple Insert Select Update and Delete in ASP.NET using MySQL Database • • • • • • • Name: • • • • • • • Address: • • • • • • Mobile: • • • • • • Email ID: • • • • • • • • • • • • • • • • • Total Student: • • • • • • • • • In the Web.config file create the connection string as in the following. In the given example:User enters the value inside the field, and click on Insert button.data is stored inside the database table.Second button is to display the value when user click on show button all information will display and with all rows a delete and edit link also displayed. Whenever user want to update he has to click on edit link or can click on delete link to delete the information. Note: Due to the size or complexity of this submission, the author has submitted it as a.zip file to shorten your download time. After downloading it, you will need a program like Winzip to decompress it. Virus note: All files are scanned once-a-day by SourceCodester.com for viruses, but new viruses come out every day, so no prevention program can catch 100% of them. FOR YOUR OWN SAFETY, PLEASE: 1. Re-scan downloaded files using your personal virus checker before using it. NEVER, EVER run compiled files (.exe's,.ocx's,.dll's etc.)--only run source code. Filtered HTML • Web page addresses and e-mail addresses turn into links automatically. • You may insert videos with [video:URL] • Allowed HTML tags: [video] • You can enable syntax highlighting of source code with the following tags:,,,,,,,,,,,,,,,. The supported tag styles are:, [foo]. • Lines and paragraphs break automatically.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
November 2018
Categories |