Parse the Aspx file (asp.net)

Source: Internet
Author: User

 

Some time ago, I wrote a simple e-mail content generation scheme, address: http://www.cnblogs.com/sheepswallow/archive/2013/05/12/3073911.html

Five methods are mentioned in this article, of which 5th points are mentioned-writing a parsing class for parsing aspx by yourself is the most difficult. I have a habit of not knowing whether it is an advantage or a disadvantage, that is, it is difficult to do it, so I checked it. the source code of net4.0 finds that to parse the aspx file, you need a subclass that implements this abstract class. The complete implementation of all abstract methods seems very difficult, so I used a simple implementation class provided by Microsoft --.

From the document, I wrote the following code:

This code can run successfully, but the returned data is not the HTML after the aspx resolution is successful, but some exception information. I will not post the specific exception information.

I checked n documents in Google and looked at the disgusting English articles. After seeing that I wanted to vomit, I found that many of them wanted to use a subclass of classes. Is it necessary to directly parse An aspx page, instead, we need to create a directory like a website and create an application domain to monitor the directory before parsing the aspx file? Lack of theoretical knowledge. I hope anyone who has read this article can answer this question.

For more information, see the following code:

When AspxCreator is used, the content after aspx resolution may be successful, but there are several problems as follows:

At the time of writing this article, the computer did not configure the running environment, so there is no way to post some, so I will write the above questions in the next article, and it may be better to add some images at that time.

I have almost never written a blog before. I am a newbie in writing a blog. I found that it is not easy to write a blog, but it is hard to write a blog with an article number, I would like to extend my sincere respect to the bloggers at the blog site. Thank you for choosing the best time to leave valuable blogs for our new users.

Related Article

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.