Posts Tagged ‘ASP.NET’

Failed to access IIS metabase

डिसेंबर 16, 2008

Today i installed IIS on my Machine, I already installed visual studio 2005,

I tried to deploy my application to the iis server, i was getting the error “Failed to access IIS metabase”,

I searched on MICROSOFT site and got the solution of the problem.

To resolve the problem:

Go to Start=>Run
type “cmd” (of course without double quotes)
type “cd C:\Program Files\Microsoft Visual Studio 8\SDK\v2.0\Bin”

type “aspnet_regiis -i”

press ENTER

you’ll see something like:
“Start installing ASP.NET (2.0.50727).
……………..”

wait for a while, and you’ll see

“Finished installing ASP.NET (2.0.50727).”

that’s all,

I deployed my project and it worked fine!!

JAI MAHARASHTRA

Embedding ASP.NET page into another page

डिसेंबर 16, 2008

First import System.IO and System.Net into the codebehind file of the page.

Take a label on the page say Label1.

add following function to the class:-

Private Function GetPageOutput(ByVal url As String) As String

Dim wr As WebRequest = WebRequest.Create(url)

Dim sr As StreamReader = New StreamReader(wr.GetResponse().GetResponseStream())

Return sr.ReadToEnd()

End Function

Take a button say Button1, in click event of Button1

call the PageOutput function as

Label1.Text=PageOutput(“http://www.google.com“)

finished, The child page content will be embeded into the current page