A journey of a thousand miles begins

Source: Internet
Author: User

The student information management system has been running for several days. Now, we will summarize the problems encountered in the past few days in the form of a journal account.

 

Before I started the student information management system, I asked myself some questions:

Can I start now? What preparations do I need to prepare for the student information management system? What is the role of being a student information system? What role will it play in future learning? What should I do during the process?

 

 

Next we will answer these questions:

Now I can work as a student information management system for the following reasons: 1. the database video has been carefully read and made notes, but there is no good summary video, which lacks an overall summary; 2. five instances have been carefully reviewed and summarized. There are many questions you don't understand, and you have also asked the master, in the future, we plan to combine these five examples into one.

 

What preparations do I need to prepare for the student information management system? 1. I need a preliminary understanding of the database. 2. You need to have a general understanding of the student information system, know what the system is, and what things in your life are related to the system.


What is the role of being a student information system? 1. The student information management system is the first system we need to do, mainly to establish the affinity between us and the Code, increase the amount of code, and have close contact with the database through practice. 2. The Student Information System is a transitional process for us to learn in the future and a process of gradual independence.

 

What should I do during the process? 1. In the process of system creation, you must not repeat a line of code. This is not easy to understand, but requires a form and a form. You must first understand its statements and logical relationships. 2. although we do not need to build our own database for this system, we need to build our own database for future systems. Therefore, in order to make a smooth transition, I think I should also try to build some simple databases and tables on my own. 3. Summary is required. Interpreting code in professional languages is sometimes hard to understand and hard to remember. Therefore, in the process of learning, you need to combine your own life summary to associate it with common things in life, so that you can easily understand.

 

 

Student information management system official ing:


Analysis:

First, we need to design the interface: the interface design seems relatively simple and can be pasted and copied, but my own creation is to add and design them one by one, only through this process can you find that your VB learning is poor. But now, it's just a perfect practice.

Then consider the form. There are many forms in this system. After a comprehensive consideration, I decided to execute the frmlogin, frmmain, and module simultaneously. These forms are closely related. This part of the module is difficult and important, and needs to be focused on. The rest of the forms are intended to be performed one by one. Their functions are relatively less independent, and they are similar and difficult.


Practice:

Module: This part takes about two days. The code is hard to understand. Below are some of its code.

Public Function executesql (byval SQL as string, msgstring as string) as ADODB. recordset dim CNN as ADODB. connection dim rst as ADODB. recordset dim metrics ens () as string on error goto executesql_error metrics ens = Split (SQL, "") 'stokens () one-dimensional array starting from scratch, split () split function set CNN = new ADODB. connection CNN. open connectstring if instr ("insert, delete, update", ucase $ (ENS ens (0)> 0 then' non-select statement CNN. execute SQL 'directly execute the SQL statement msgstring = ens (0) & "query successful" else' SELECT statement set rst = new ADODB. recordset rst. open trim $ (SQL), CNN, adopenstatic, adlockoptimistic 'Get the temporary table, and the cursor points to the first record set executesql = rst msgstring = "found" & rst. recordcount & "record" end if executesql_exit: Set rst = nothing set CNN = nothing exit function executesql_error: msgstring = "query error:" & _ err. description resume executesql_exitend Function

Three functions are used: Split (), instr (), and ucase (). You can use these functions to query the function manual. The above is a comprehensive explanation. After a single function is understood, the next step is to understand the items in the IF statement block. It is best to make a general understanding:

That is, if

"INSERT,DELETE,UPDATE"

Found

UCase$(sTokens(0)

Execute the SQL statement (that is, non-select: insert, delete, update). If not, execute the following SELECT statement and return the result.

 

Set rst = new ADODB. recordset RST. Open trim $ (SQL), CNN, adopenstatic, adlockoptimistic set executesql = rst msgstring = "found" & RST. recordcount & "Record



The module also has a line of code that is important, but looks simple. In fact, the code that requires more attention will be written and analyzed in the next blog.


The journey of a thousand miles begins with the beginning of my student information management system. There are many more work to be done later.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.