How to run a asp.net project with a single file. [Resolved]

Posted by Cibin under ASP.NET on 6/11/2013 | Points: 10 | Views : 1563 | Status : [Member] | Replies : 22
Hello Sir,

I already developed a website in asp.net. Now i want to load my website from a single file.Which means when i double click in my master page,all the other pages associated with it wants to work. And also how to publish my website in my own system, If you give a step by step process will make me more easier to do that.


Thanks in Advance,,,,,




Responses

Posted by: Raj.Trivedi on: 6/14/2013 [Member] [MVP] Starter | Points: 50

Up
0
Down

Resolved
Hello

You can bind the website to IIS and then call the home page of the website.

One more thing You cannot run a website from masterpage because it is not an .aspx or an .html page. it is a master file with extension .master

Check this for binding the website in IIS


http://www.dotnetfunda.com/articles/article2217-binding-a-website-to-local-iis.aspx

Regard's
Raj.Trivedi
"Sharing is Caring"
Please mark as answer if your Query is resolved

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Raj.Trivedi on: 6/16/2013 [Member] [MVP] Starter | Points: 50

Up
0
Down

Resolved
Hello cibin

The link that i have pasted will also give you complete detail of binding the website to lan server having iis...



Regard's
Raj.Trivedi
"Sharing is Caring"
Please mark as answer if your Query is resolved

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Raj.Trivedi on: 6/16/2013 [Member] [MVP] Starter | Points: 50

Up
0
Down

Resolved
hello cibin,

there is no other folder to be shared

just make sure that your system has a private static ip and it is in same lan

Regard's
Raj.Trivedi
"Sharing is Caring"
Please mark as answer if your Query is resolved

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Raj.Trivedi on: 6/16/2013 [Member] [MVP] Starter | Points: 50

Up
0
Down

Resolved
Hello Cibin ,

It depends if you are keeping the name of the database same then you dont have to change the name of the database but yes you will have to change the data source which will have IP address of your system you will have to make it to your LAN Server ip

EG :-

if your system ip is 192.168.1.25

and lan server is 192.168.1.30

then

connection string should be

"data Source=192.168.1.30;Intial Catalog= Databasename;User id=yours sqlserverusername;password= yoursqlpassword"

Regard's
Raj.Trivedi
"Sharing is Caring"
Please mark as answer if your Query is resolved

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Raj.Trivedi on: 6/17/2013 [Member] [MVP] Starter | Points: 50

Up
0
Down

Resolved
hello cibin

you dont have to use local host again just use the ip address and call the home.aspx if you are calling from a different machine.

This way

http://10.1.2.75/home.aspx

no need of local host while calling from another machine.



Regard's
Raj.Trivedi
"Sharing is Caring"
Please mark as answer if your Query is resolved

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Bageshkumarbagi on: 6/11/2013 [Member] Starter | Points: 25

Up
0
Down
Hi Cibin,

Folowing link may be useful to you..
http://www.devmanuals.com/tutorials/ms/aspdotnet/masterpage.html
http://msdn.microsoft.com/en-us/library/aa581781.aspx

try with them.

Thanks,
Bagesh Kumar Singh

Thanks,
Bagesh Kumar Singh
Mark as answer if you have been satisfied

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Cibin on: 6/11/2013 [Member] Starter | Points: 25

Up
0
Down
Actually I want to run my website, without the help of visual studio 2010,, How to do that ...

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Allemahesh on: 6/14/2013 [Member] [MVP] Silver | Points: 25

Up
0
Down
As per my experience, You cannot run asp.net project form single file. We need visual studio or IIS server to runt the asp.net website. Hope this will clear your idea.

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Cibin on: 6/16/2013 [Member] Starter | Points: 25

Up
0
Down
Thanks Mr. Raj. Now i want to know ,,, how to host this in my LAN server.

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Cibin on: 6/16/2013 [Member] Starter | Points: 25

Up
0
Down
ya ,, I had seen that,, But i Convert that virtual directory to application. Its not working ,, am getting an error....

HTTP Error 500.19 - Internal Server Error
The requested page cannot be accessed because the related configuration data for the page is invalid.


Module IIS Web Core
Notification BeginRequest
Handler Not yet determined
Error Code 0x800700b7
Config Error Cannot add duplicate collection entry of type 'add' with unique key attribute 'name' set to 'CrystalImageHandler.aspx_GET'
Config File \\?\C:\inetpub\wwwroot\web.config
Requested URL http://localhost:80/tit
Physical Path C:\inetpub\wwwroot
Logon Method Not yet determined
Logon User Not yet determined
Config Source

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Cibin on: 6/16/2013 [Member] Starter | Points: 25

Up
0
Down
Now, Its resolved,,,, My another Question is : If we make my system as server, if there is any folder we make to shared.


Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Cibin on: 6/16/2013 [Member] Starter | Points: 25

Up
0
Down
Thanks Raj,,

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Cibin on: 6/16/2013 [Member] Starter | Points: 25

Up
0
Down
One More Question: How to Copy the instance of SQL Server from my system to my LAN Server

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Raj.Trivedi on: 6/16/2013 [Member] [MVP] Starter | Points: 25

Up
0
Down
Hello Cibin

Just take a back up of your database and then go to the lan server create a new database and then restore the database that you have backed up from your system

Regard's
Raj.Trivedi
"Sharing is Caring"
Please mark as answer if your Query is resolved

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Cibin on: 6/16/2013 [Member] Starter | Points: 25

Up
0
Down
then wat about the Connection String,,,We need to change that?


Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Cibin on: 6/16/2013 [Member] Starter | Points: 25

Up
0
Down
So there is no importance for the sql instance

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Raj.Trivedi on: 6/16/2013 [Member] [MVP] Starter | Points: 25

Up
0
Down
Hello Cibin,

You are correct you just have to make sure the credentials are correct of the server and the data source

Regard's
Raj.Trivedi
"Sharing is Caring"
Please mark as answer if your Query is resolved

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Cibin on: 6/16/2013 [Member] Starter | Points: 25

Up
0
Down
Ya, So When we install the sql server in server , we create the instance with same credentials , right?


Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Raj.Trivedi on: 6/16/2013 [Member] [MVP] Starter | Points: 25

Up
0
Down
Hello Cibin,

You got it bulls eye absolutely correct...you have got it

Regard's
Raj.Trivedi
"Sharing is Caring"
Please mark as answer if your Query is resolved

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Cibin on: 6/16/2013 [Member] Starter | Points: 25

Up
0
Down
Thanks Raj, Thanks for your help..

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Cibin on: 6/17/2013 [Member] Starter | Points: 25

Up
0
Down

Hi,

When i call my website like this : http://localhost/Home.aspx..... Its Working,,,, But when i call this website like this : http://10.1.2.175/localhost/Home.aspx . From my another system in same LAN .Am getting an error.

Server Error in '/' Application.

The resource cannot be found.

Description: HTTP 404. The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable. Please review the following URL and make sure that it is spelled correctly.

Requested URL: /localhost/Home.aspx

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.1

My IP address is : 10.1.2.175

What will I do ?

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Cibin on: 6/17/2013 [Member] Starter | Points: 25

Up
0
Down
Thanks Raj,, Now I had a another doubt, That i posted in the forum.Can please check it and reply me.

Cibin, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response