|
I had a look at the link you quoted. The console application is the client. It should work. Make sure that your console project is the start up project. Right click on the project from Solution Explorer and click "Set as Startup Project".
|
|
|
|
|
Actually in my solution I have only one project, web service project. Actually I don't know, until you guys mentioned it, that a web service need a web application to start work.
I appreciate your help all the time...
CodingLover
|
|
|
|
|
To give you a pointer, once you have added a Web Reference to your project, you can call the HelloWorld WebMethod, say from Page_Load, as follows:
protected void Page_Load(object sender, EventArgs e)
{
localhost.Service1 hello = new localhost.Service1();
lblHello.Text = hello.HelloWorld();
}
where,
localhost is your Web reference name, lblHello is a label on your web form, and Service1 is the name of your web service
|
|
|
|
|
Thanks a lot. Before that I want to know one thing.
Now I have two project in my solution, a web application and a web service. How can I add a reference to the web service in the web application. And how I add your code there.
I appreciate your help all the time...
CodingLover
|
|
|
|
|
Just right-click on the project (Web Application) from Solution Explorer, click on Add Web Reference. You will get a dialog box. Under a label: [Browse to:] click [Web services in this solution]. VS will discover all the web services in your solution and they will be presented in a list. Click on the one you want to use and, after giving it an appropriate web reference name add it (VS might suggest something like 'localhost'). You will then be ready to go. You can add the sample code on the Page_Load of a web form in your web application.
|
|
|
|
|
Thanks lol, I'll try and let you know what happen in my side.
I appreciate your help all the time...
CodingLover
|
|
|
|
|
Ok, As you said I add reference into the web application of the web service. I can build the solution fine, but I cannot run it. How can I run the web application? Please help me.
I appreciate your help all the time...
CodingLover
|
|
|
|
|
Wow, nice work lol. I've figured what the mistake I've done.
Seems to me using the IDE, just pressing F5, cannot run the web application. I have to type the URL and run the browser. It's working fine. Is that right lol.
I appreciate your help all the time...
CodingLover
|
|
|
|
|
I need to bind the SitemapDataSource to ListView.
And I need to show the sitemap as follows:
Home
node a| node aa| node aaa
| | node aab
| | node aac
------------------------------
| node ab| node aba
| | node abb
| | node abc
------------------------------
node b| node ba
| node bb
| node bc
The leaf nodes within the same parent node are contained in one table cell.
The annoying thing here is that:
Sometimes "node aa, node ab" is separate into two cells if they have child nodes.
But "node aa, node ab" will merge into one cell if they don't have child nodes.
Can anyone think of a good solution to show the data?
Should I use ListView in this case? Is there any easier way to do this?
Thanks.
|
|
|
|
|
i wanna use the hashtabl concept to fill the dropdownlist and use the hashtable in the selected item change event of the dropdownlist .. but wenever i refresh the page it shows the error
"Item has already been added. Key in dictionary: "10" Key being added: "10" "
and i chked the databse and i dont have the duplicate keys ... but i still get this error ..can anyonehelp wat cud be the reason and how to solve it and the code snippet is (in the page load event )
OleDbDataAdapter ada = new OleDbDataAdapter("Select * from HOSP",oledb);
DataTable Dhosp=new DataTable();
ada.Fill(Dhosp);
hHospital2.Clear();
foreach(DataRow row in Dhosp.Rows)
{
if (hHospital2.Contains(row["HOSPID"].ToString()))
{
Response.Write(row["HOSPID"].ToString());
}
else
{
hHospital2.Add(row["HOSPID"].ToString()+"~"+row["HOSPADD"],row["HOSPNAME"].ToString());
hLH.Add(row["HOSPNAME"],row["LOCATION"]);
}
}
HospId.DataSource = Dhosp;
HospId.DataMember="Hosp";
HospId.DataTextField="HOSPNAME";
HospId.DataValueField="HOSPID";
HospId.DataBind();
|
|
|
|
|
I suspect its telling the truth. Have you tried running in debug and actually seeing when it goes wrong - postback perhaps?
Bob
Ashfield Consultants Ltd
|
|
|
|
|
yeah exactly ..during the postback it gives this error ....
|
|
|
|
|
Thats the problem then. Don't do the load during postback, it isn't needed.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
You are databinding the control on postback also. That means that you will re-add all the elements that the control already keeps in ViewState.
Either only databind on the initial load, or keep the control from using ViewState.
Despite everything, the person most likely to be fooling you next is yourself.
|
|
|
|
|
|
This should help[^]
Bob
Ashfield Consultants Ltd
|
|
|
|
|
|
Don't Repost
Sathesh.
Blessed is the season which engages the whole world in a conspiracy of love.
|
|
|
|
|
I want to write a complex system that does all sorts of complex stuff. I am a beginner. What's wrong with this picture ?
Christian Graus
Driven to the arms of OSX by Vista.
"Iam doing the browsing center project in vb.net using c# coding" - this is why I don't answer questions much anymore. Oh, and Microsoft doesn't want me to.
|
|
|
|
|
Hi,
I am trying to a website similar to Google doc,the website should be able to handle,document files, spreadsheet,presentation,images.the files can be viewed,edited and deleted based on the permission .
The Important point is that all the manipulation,such as editing,viewing and deleting is done online,the files should not be downloaded to the client system.the client can view a document online and based on this permission, he can act.
step 1: the file will be uploaded to the website.
step 2: the user can view the file online.
step 3: If wanted he can share or edit the file.
step 4: If shared, the person to whom it is shared can log in and view the file.
all the above actions are done in the website,the file strictly cant be downloaded.(important Viewing is done in the website).
i am a beginner, i am not sure how to begin,so it would help me out if some one can point me in the right direction.Thanks in advance
Regards
Navin
|
|
|
|
|
Clickety
Sathesh.
Blessed is the season which engages the whole world in a conspiracy of love.
|
|
|
|
|
kindly tell me ,i have to fetch some records from the database and convert it to XML, using XSLT.
|
|
|
|
|
If you are using SQL Server (and probably Oracle supports it too) you can select directly into XML from the database. Google for AS XML should give you loads of examples.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
I have menu control declared like the below:
<div>
<asp:Menu...
menu items here
</asp:Menu>
I have 40 menu items. All these are displaying in one line with the horizantal scrollbar is displaying fro the page. How to avoid the horizantal scroll bar? When the width exceeds 100%.
Thanks in advance
|
|
|
|
|
I would recommend you to first calculate the width of page then re-size your menu items accordingly.
OR
show them in multiple lines if you can not resize
Ahsan Ullah
Senior Software Engineer
|
|
|
|