.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Post New Web Links

Adding a reference insanity

Posted By:      Posted Date: September 15, 2010    Points: 0   Category :ASP.Net
 
So I have a solution that is somewhat designed like this|Solution|-project DAL|-project commons|-project ServerSideStartUp       -public class startUp (public constructor startUp)|-project windowsService      -service service1Now I can reference commons from the windowsService with no problems. I can also reference serverSideStartup. When I add the reference and start typing code I even get the correct intellisence. At this point there I would have no reason for being here. Unfortunately after I build I get Error    3    The type or namespace name 'ServerSideStartUp' could not be found (are you missing a using directive or an assembly reference?)    Which to me would say I forgot to reference it. But 2 minutes before I added the reference and was even using the intellisence to help write the code.Have any of you ever run into this problem? Also if I add or remove another reference the project knows about the reference.Any ideas or advice?


View Complete Post


More Related Resource Links

Adding web reference

  
Hi All,I have VS 2008 professional. I have created a web service. In one of my websites I want to add this web service. When i clicked on add web reference > web service on local machine, it is giving the error The Web services and Discovery Documents available on your VS.NET developer machine are listed below. Click the service link to browse that service. There was an error while enumerating services on local machine: Active Directory Services cannot find the web server. A possible cause for this is an incompatibility between versions of Internet Information Server (IIS) on the client and the server. Another possible cause is that IIS is not installed on the local machine, or the user identity under which you are running may not have permissions to view websites on this machine. To view websites on this machine, make sure that you run Visual Studio as administrator. On Windows Vista computers with IIS installed, make sure that IIS Metabase and IIS 6 configuration compatibility feature is enabled. If i run the VS as administrator and try to do the same thing, it will show The Web services and Discovery Documents available on your VS.NET developer machine are listed below. Click the service link to browse that service. None - No Web services were found on the local computer. Plz help to solve this.Smitha

Problem adding a Service Reference

  

Hello all.

I am developing a Web Application using Visual Studio 2010 in witch I have to add a Service Reference to http://dev.virtualearth.net/webservices/v1/geocodeservice/geocodeservice.svc?wsdl.

The problem is that my company's network requires a proxy authentication. So when I enter the "Add Service Reference" dialog, paste the url and click "go" I get a "(407) Proxy Authentication Required" error and cannot add the service.

I also tried using svcutil but the result, obviously, was the same.

How can I work around this? Is there somewhere I can specify the required proxy? Googling around, I found some comments that it can be specified in the Web.config, but I can't find more details on how to do this.

Thanks in advance.


Error while adding reference to latest version of AjaxControlToolkit

  

HI All,

I am a bit new to ASP.Net Ajax and as such new to Ajax itself. I have a site which uses ASP.Net Ajax.  It used the version AjaxControlToolkit version 3.0.30512.0. I have now changed it to version 3.5.40412.2 by deleting the old reference and adding a reference to the latest one . I build the soultion and everything appears fine witjhout any errors. But the site fails to load showing a yellow page with the message AjaxControlToolkit Version="3.5.40412.2" missing reference to 'AjaxControlToolkit.ExtenderBase.Base Scripts.js.BaseScripts.js'. What does this mean ?


How to invoke c# function from another project without adding reference?

  

Hi,

There is a C#.net libraray project whose dll name is customer.dll. It has a class name customer with a function name show(). I want to call this function from another project but dont want to add reference to the caller project. Can this be done? Is there any C#.net class that can acheive this?


Adding a reference to Microsoft excel object library

  

Its my first website with Visual studio 2005 and one of the things I used t do in VS2003 was to add the reference to Microsoft excel object library.

but the reference will not add, it does not give any error just goes back to the ide with no reference in the bin folder.

has anyone seen this or know what it is?


when adding web reference, I get "Operation is not valid due to the current state of the object."

  

 Hello.

I am trying to add a Web reference to a project.  So, I do the standard: right clicking on the project and select "Add Web Reference". The Add Web Reference appears and I navigate to the desired URL "http://ws.melissadata.com/dqws/Address.asmx" and click "Go".   This works in IE.  I see the results and two methods in the window.  However,  the "Add Reference" button and " Web Reference Name" texbox is disabled. And, I see the Operation is not valid due to the current state of the object." I think this is a proxy and or firewall issue?

 

I know the System.Net.WebProxy("corp-xxx-proxy.xxx", 8080);  and System.Net.NetworkCredential("xxxx", "xxxx"); [x replaces real values]

 Any ideas where I can set this info so I will be able to use the "Add Web Reference" wizard?  - OR - Is there a workaround?

 

 

thanks


On adding WCF Service reference element is not created

  

Hi Friends,

I am using x.509 certificate based authentication in my WCF service. In development stage, I created a x.509 certificate using makecert utility. Installed it on my local machine. Added the reference to the certificate in my WCF service. When I added the service reference to my Test App, following element got created in the app.config file of the Test App.

            <endpoint address="http://localhost/MyService/MyService.svc"
                binding="wsHttpBinding" bindingConfiguration="wsHttpEndpoint"
    contract="MyService.IMyService" name="wsHttpEndpoint">
                <identity>
                    <certificate encodedValue="Long encoded string..." />
                </identity>
            </endpoint>

I then deployed the WC

On adding WCF Service reference element is not created

  

Hi Friends,

I am using x.509 certificate based authentication in my WCF service. In development stage, I created a x.509 certificate using makecert utility. Installed it on my local machine. Added the reference to the certificate in my WCF service. When I added the service reference to my Test App, following element got created in the app.config file of the Test App.

            <endpoint address="http://localhost/MyService/MyService.svc"
                binding="wsHttpBinding" bindingConfiguration="wsHttpEndpoint"
    contract="MyService.IMyService" name="wsHttpEndpoint">
                <identity>
                    <certificate encodedValue="Long encoded string..." />
                </identity>
            </endpoint>

I then deployed the WC

On adding WCF Service reference element is not created

  

Hi Friends,

I am using x.509 certificate based authentication in my WCF service. In development stage, I created a x.509 certificate using makecert utility. Installed it on my local machine. Added the reference to the certificate in my WCF service. When I added the service reference to my Test App, following element got created in the app.config file of the Test App.

            <endpoint address="http://localhost/MyService/MyService.svc"
                binding="wsHttpBinding" bindingConfiguration="wsHttpEndpoint"
    contract="MyService.IMyService" name="wsHttpEndpoint">
                <identity>
                    <certificate encodedValue="Long encoded string..." />
                </identity>
            </endpoi

adding a service reference throws a contract error

  

Hi

I added a service reference via the add service reference method. I can see all of its services in the intellisense but when I run the project and it executes the line where I instantiate the service : MyProjectName.ServiceReferenceName.IServiceReferenceClient  client = new  MyProjectName.ServiceReferenceName.ServiceReferenceClient;

it throws this error:

Could not find default endpoint element that references contract 'ServiceReferenceName.IServiceReferenceClient' in the ServiceModel client configuration section. This might be because no configuration file was found for your application, or because no endpoint element matching this contract could be found in the client element.

 

Now this within my class library and I have added the service reference in my class library project.

Kind Regards

Ernst


Error adding a web reference...how do I fix this?

  

I am currently just trying to add a web reference to the app am trying to build and I keep getting an error each time I try to navigate to the URL (virtual directory) where I have my app locally...IIS.

The error that keeps popping up and I can't seem to get rid of this wrinkle...I am the admin on my personal machine, so I should have all permissions...which I do.

This is the error I keep getting. And here are what I have tried so far that has not resolved this

1) made sure that there were no duplicate accessType entries in the ApplicationHost.config and the web.config files

2) granted the READ permission to the IIS_IUSRS group for the ApplicationHost.config file

3) also granted the READ permission to the IIS_IUSRS group for the virtual directory

---this is on a Windows 7 machine with IIS 7. Please help...Thanks

HTTP Error 500.19 - Internal Server Error

The requested page cannot be accessed because the related configuration data for the page is invalid.

Detailed Error Information
Module IIS Web Core
Notification BeginRequest
Handler Not yet determined
Error Code 0x80070005
Config Error Cannot

finding url to use when adding a service reference

  

I have sample code from stamps.com to access their SOAP style web services.  I would like to create a new project and add a service reference to it for the Stamps.com soap web service. How do I get the correct URL from the working project to use when adding the service reference to the new project?

I click properties of the web reference in the working stamps.com supplied project.  The web reference URL is https://swsim.testing.stamps.com/swsim/swsim-v4-wsdl.aspx

In another project, I click "add service reference", then paste that URL into the address line and click Go. Get back an error:
There was an error downloading 'https://swsim.testing.stamps.com/swsim/swsim-v4-wsdl.aspx'.
The request failed with HTTP status 404: Not Found.
Metadata contains a reference that cannot be resolved: 'https://swsim.testing.stamps.com/swsim/swsim-v4-wsdl.aspx'.
There was no endpoint listening at https://swsim.testing.stamps.com/swsim/swsim-v4-wsdl.aspx that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details.
The remote server returned an error: (404) Not Found.

thanks,

 


while adding service reference in .net 2008

  

The document at the url https://hostname/app1/abc.svc was not recognized as a known document type.
The error message from each known type may help you fix the problem:
- Report from 'DISCO Document' is 'There was an error downloading 'https://internalsystemname/app1/abc.svc?disco'.'.
  - The request failed with HTTP status 502: Proxy Error ( No data record is available. For more information about this event, see ISA Server Help.  ).
- Report from 'WSDL Document' is 'The document format is not recognized (the content type is 'text/html; charset=UTF-8').'.
- Report from 'https://hostname/app1/abc.svc' is 'The document format is not recognized (the content type is 'text/html; charset=UTF-8').'.
- Report from 'XML Schema' is 'The document format is not recognized (the content type is 'text/html; charset=UTF-8').'.
The document at the url https://hostname/app1/abc.svc was not recognized as a known document type.
The error message from each known type may help you fix the problem:
- Report from 'DISCO Document' is 'There was an error downloading 'https://internalsystemname/app1/abc.svc?disco'.'.
  - The request failed with HTTP status 502: Proxy Error ( No data record is available. For more informatio

Problem while Adding reference of my Wcf Service

  

Hi

I have my wcf service hosted in the iis of the my development server.I am able to directly access the url of the service from both the server and the client browsers.I am also able to see the wsdl generated.

But when i add service reference from Visual studio 2008/2010,i get the following error..

The document at the url http://something.svc was not recognized as a known document type.

The error message from each known type may help you fix the problem:

- Report from 'http://something.svc' is 'The document format is not recognized (the content type is 'text/html; charset=UTF-8').'.

- Report from 'DISCO Document' is 'There was an error downloading 'http://something.svc?disco'.'.

 - The request failed with HTTP status 503: Service Unavailable.

- Report from 'XML Schema' is 'The document format is not recognized (the content type is 'text/html; charset=UTF-8').'.

- Report from 'WSDL Document' is 'The document format is not recognized (the content type is 'text/html; charset=UTF-8').'.

Metadata contains a reference that cannot be resolved: 'http://something.svc'.

The HTTP request is unauthorized with client authentication scheme 'Anonymous'. The authentication header received from the server was 'Negotiate,NTLM'.

The remote server returned an error: (401) Unauthorized.

If the service is defined in the current 

Problem adding service reference to web services in VS 08

  

Hi,

I’ve been trying to write some C# in Visual Studio 2008 to leverage SharePoint Web Services. I’ve scoured the web for help on this problem. I’m just beginning to learn .NET programming, but I’ve done a bunch with SharePoint Web Services with javascript and then with jQuery.SPServices.

 

If I start a new Console Application project and try to add a Service Reference, I put in my url: …/_vti_bin/Authentication.asmx and try to attach it. It tells me that there’s a problem with the certificate (which I get in the browser and SP Designer).

 

I get this error:

The HTML document does not contain Web service discovery information.
Metadata contains a reference that cannot be resolved: 'https://example.com/myCollection/_vti_bin/Authentication.asmx'.
The HTTP request is unauthorized with client authentication scheme 'Anonymous'. The authentication header received from the server was 'Basic Realm="example.com"'.
The remote server returned an error: (401) Unauthorized.
If the service is defined in the current solution, try building the solution and adding the service reference again.

If I click Advanced and Add Web Reference, I try again. This time, the browser window brings up the form we use to authenticate. From what I understand about the architecture, the MOSS

Errors after adding a web reference in code

  

after adding a web reference in my code m gettiing somany errors lyk-Error 1 The type or namespace name 'XmlNode' could not be found (are you missing a using directive or an assembly reference?) C:\Documents and Settings\288122\My Documents\Visual Studio 2005\Projects\New Folder\MovingFiles\MovingFiles\Form1.cs 
this code is for moving attachment  from a custom list in share point

into folder


tanvi sharma

A better way to reference your wizard steps using named steps

  
Note: this article uses the plain vanilla but the concepts apply equally well to its popular counterpart .

By far the most common way that I see wizard steps reference in code snippets is by their index.
Categories: 
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend