2. Database
After I made a little thing, I wanted to send it to the Internet. I used dynamic hosts and had no money to rent space. I thought that day, when we had money, we rented 2 Virtual Hosts and dual-Machine backup. You can see that your
For a long time, I want to write some component applications. During this time, I can finally write something I like.
I hope you can write your own components as you like after learning these tutorials.
Each article may not be associated, but it is
Seven articles have been written in the preliminary tutorial. There must be some preliminary things to write. I will add them slowly.
Intermediate tutorial content:
This may also be the most important concern: database operations and
Let's take a look at the application object.
Previously, application objects were often used for the connection string between counters and databases.
Take the counter as an example:
Check the global. Asa file first. This is relatively simple.
Session is much simpler than session.
View
Open VB6 and create an ActiveX dll project. Change project name to fcom and class name to fz3Reference the "Microsoft Active Server Pages object" Object Library.Create two component events: onstartpage and
How to use attributes
Open VB6 and create an ActiveX dll project. Change project name to fcom and class name to FC2
Choose> Tools> Add process.
Enter myname in the name, type selection attribute, range selection public, and then OK
Operation again:
Array Problems
Arrays are used in many programs and are prone to problems.
Let's take a look at the small example
Open VB6 and create an ActiveX dll project. Change project name to fcom and class name to FC4
Choose> Tools> Add process.
Enter
Let's make a component, a component that can generate a guid
Guid)
A guid can be expressed as a 32-character hexadecimal format. Com provides a system-level function named cocreateguid, which can be used to generate a new guid. This function relies
Error Handling
If an error occurs on the page but the error is not processed, the page displays an error that the user may not understand.
Can be used in ASP scripts
On Error resume next
......
If err. Number <> 0 then
Response. Write err.
Let's take a look at the response object. In fact, we have been using the write method of this object in the previous tutorial.
Here we use the response object to set the cookie.
?
Open VB6 and create an ActiveX dll project. Change project name
As a built-in ASP object, we finally learn server objects.
Server objects use HTML encoding, URL encoding, and webpage redirection and transmission.
?
Open VB6 and create an ActiveX dll project. Change project name to fcom and class name to
Start database operations.
Common component Encapsulation
1 .? Encapsulate the database connection information.
1> ???? Directly return the database connection string, for example, in the component
Public? Function? Datasource ()? As?
No matter what method, image, EXE, or RAR ====, you only need to change the suffix to ASP through other methods, but you need to insert a language in ASP:
Save.
Then, the local structure of the submission form, the content of the action points
Learning to use stored procedures is a must for ASP programmers. All large databases support stored procedures, such as Oracle and ms SQL. (However, MS Access is not supported. However, parameterized queries can be used in access ).Stored Procedures
During this time, the future of ASP and the discussion about ASP are better. Of course, everyone's heart is good, but what some friends say is really depressing .......
In my opinion, ASP will be applied to B/S systems of many small and medium
Demo: http://goaler.xicp.net/RssReader.asp
RSS Resource: "onfocus = select ()> & nbsp; double-click the mouse to close the abstract. Only the title is displayed.If (Request ("rssfeed") = "") thenUrl = "/rss2.asp"ElseUrl = request ("rssfeed ")End
From: http://www.guoblog.com/blogview.asp? Logid = 202
Public Function valuesepr (byval rawstring as string, byval sepchar as string) as stringIf instr (1, rawstring, sepchar) <> 0 thenValuesepr = Microsoft. VisualBasic. Right (rawstring, Len
From: http://edu.cn700.com/
After reading this, you can use ASP to modify the registry!
Have you heard of the well-known wsh? It is short for Windows Script Host, and wsh is a script command on Windows platform. It has powerful functions, in
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.