Forum Moderators: open
First of all, what is the best way to manage a site that mixes asp and html? I mainly edit and code my site in Dreamweaver, but when I want to use ASP.NET i crack open Visual Studio. I've been creating asp pages/projects wrong tho....i usually create a C# web application, which sets up seperate .aspx and .aspx.cs codebehind files. When i first noticed this i decided to give it a try, thinking that it might be nice to separate the heart of my C# code and my html. However, it took some time to realize that a Web Application is actually a VS project that creates a dll of the compiled codebehinds instead of just interpreting the server side code on the fly. I was having to remove the "SRC" attribute while testing locally and then since I didn't "publish" my web application the dll never made it up to the server and i had to reinsert the "src" attribute that pointed to the aspx.cs codebehind. So when you are developing a site from scratch, is there a convenient way to establish an ASP.NET project for the whole site that does not rely on compiled dlls? I want to have all my asp.net files that i will be using in the same project in Visual Studio.
OK, next question. I have set up a couple of asp.net pages that access the same MS Access database. All they do is return rows from a "Dates" table for when my band is playing. One page populates a Calendar control and the other dynamically creates a table that contains the date/gig info. The work super fast most of the time, but it seems as tho if someone accesses one of these pages and then just leaves the window open, other people trying to access have to wait a long time. I will post the code below shortly. Maybe i'm not closing a reader or connection?
If I were to use one dll, it seems that instead of naming the solution DateManager or SongManager I should name it MySiteApps.dll and have the DateManager and SongManager as projects within the solution. Sound like I'm on the right path?
May I ask what made you decide asp to asp.net vs php5 or something? I am guessing because most of the site was already in asp. that is cool though.
as far as your DB is concerned, Access wasn't really created to be a large scale DB with multiple people accessing it at the same time over the net. (Basically) the way it handles its threading for different tasks and access attempts it doesn't do well and it's performace degrades faster over time. You really need something that Small Web Site Guy suggested...like Sql Server. Hope that helps.
oh yeah...If date manager and Sound manager is two different sites then it would make sense to have them in the same solution. They will compile respectively but the solution doesn't compile to a dll...that is just a file that sits there that manages your projects...it allows you to different things inside studio to handle them differently or the same.
Don't get me wrong though, I have a linux box that harnesses the power of the open source php community, using the OSCommerce and PHPBB applications. I love them! However, since they were so easy to configure I have yet to really get my hands dirty working with php.
The Access stuff: I used access for a couple or reasons. The NT box that I'm running my ASP site off of doesn't include MYSQL free of charge. Also, this is not a user heavy site, its just my band website. It would be hard to imagine two people hitting the DB at the same time so I though Access would work...also, since I closed that reader object I haven't seen the same latency as before so perhaps the problem is solved.
OK, well if you guys think that I should harness the full power of the new ASP.NET then I will continue to develop full fledged web applications. I just need to consolidate my different projects into one solution. Does the web publish feature of visual studio allow you to publish only one project? Are there seperate dlls for each project? I would guess so.
I also guess this means good bye to forcing the "SRC" attribute in my page directive on the aspx file!
Thanks again, and any other pointers you may have are more than welcome!
I do know that in a client/server environment the performance is really bad, because an Access DB is just a dumb file that the JET driver on the client machine reads and interprets.
Maybe in a web environment it would work better because it's all on the same machine... no network traffic issues, and if it's a single processor machine the database is probably being read only once at a time (which in itself doesn't sound that scaleable).
People avoid SQL Server because it costs money: $5000/processor. A real bargain if you consider how much developers chage per hour, but lots of people are "penny wise pound foolish."
While not everything MS does is great, I think that SQL Server and ASP.NET are great products.
As for access, like people said, I suggest you get a copy of mysql (should be free if you don't make money out of it)
Another note, dll compiled by VS.Net are not "usual" dlls, sonce you can overwrite the file like any other file, you don't need to unload it from memory before.