Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Creating ASP.NET/HTML pages 100% programmatically 2

Status
Not open for further replies.

bitseeker

Programmer
Nov 27, 2005
60
US
Is it a possible create HTML pages 100% programmatically? Particularly in VS2005, this would mean creating an empty .html file, putting it into a member pages folder, "figuring out" and adding HTML to the file, closing it, and associating it with a code behind file.

I'm not sure WHY I would do it, but I would like to know if it's possible to do all these step(and, if it's in fact a "standard practice" in some situations).

Thanks!
 
I have never taken it to the extent you are describing. And like you said, I am not sure why someone would want to do it. I have done pages where all the controls on the page were created dynamically.

Jim
 
You could do it as you could simply create both files and call the .NET compiler to compile the files. You wouldn't ever need to do it though...


____________________________________________________________

Need help finding an answer?

Try the Search Facility or read FAQ222-2244 on how to get better results.

 
Thanks for the inputs. My take-aways are that it's possible, but that it's not a "standard practice" because there aren't any significant use cases for it. Meaning, in virtually all cases, the app designer will know that they need a page, and will draft at least a shell of the page in some tool and place it on the web site, where it can be programmatically modified before or during)use. OK! Thanks!

 
hi,

In the old days there was a technique that used Code to write the html then the javascript document.write was used to create the page.

this is kinda what you are talking about.

the drawbacks to what you are suggesting is the CPU usage to create the page over and over. That is why we have the template page (aspx) and fill in the blanks with dynamic stuff.


also somewhere in my aging and clouding memory I remember soething about SQL server having the ability to create HTML pages from a template that you could trigger to rebuild on changes or on a schedule.....but that was a long long time ago

just some thoughts

bassguy
 
bassguy: thanks for the input. helps to have the perspective!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top