c# - can asp.net run without .net framework -
c# - can asp.net run without .net framework -
i new asp.net. inquire can asp.net run without .net framework? in can default.aspx run smoothly without .net framework? asking due next existing code runned on web hosting server , private server. not sure private server details ( going know in 2-3 days)...the code goes as...
try { webrequest req = webrequest.create(general.siteurl + "/pages/" + page + ".htm"); webresponse resp = req.getresponse(); stream stream = resp.getresponsestream(); streamreader reader = new streamreader(stream); content = reader.readtoend(); } grab { content = "<html><head></head><body>content not found.</body></html>"; }
the web hosting server manage run "try" whereas private 1 shows content not found....any ideas guys?
people visit website not need .net framework; they'll need browser.
the server runs website need .net framework since asp.net part of it.
the .net framework required on server side few reasons (these examples):
your code compiled intermediate language designed platform agnostic. runtime (the .net framework) required convert intermediate language machine can understand. accomplished jit. there several libraries in asp.net; system.web.dll; example. these distributed part of .net framework. the code hosted within of virtual machine (in non-traditional sense). virtual machine takes care of lot of heavy lifting you; such security; garbage collection; etc. again; part of .net framework.edit:
i think asking wrong question here. inquire wondering why code going within of catch
block , returning content not found.
.net framework installed since grab block beingness called; in fact couldn't far without .net framework.
you need figure out exception beingness thrown within of try
block causing go catch
block. can accomplish debugger; logging; or temporarily removing grab block server allow exception bubble way top. example; if alter code block this:
webrequest req = webrequest.create(general.siteurl + "/pages/" + page + ".htm"); webresponse resp = req.getresponse(); stream stream = resp.getresponsestream(); streamreader reader = new streamreader(stream); content = reader.readtoend();
the exception details displayed in browser (provided have debugging turned on). error displayed without seek / catch?
c# .net asp.net frameworks
Comments
Post a Comment