Namespace for Credentials - c#

I wanted to write credential for web services like this
private Credentials credentials;
But i am getting error to this line that
The type or namespace name 'Credentials' could not be found (are you missing a using directive or an assembly reference?)
Calling Web Service using ASP.NET

I suspect it's in the ExtentrixWS namespace - which means you need the ExtentrixWS library. But are you actually consuming an ExtentrixWS web service?

Related

C# Youtube API Errors

When I want to write code with the YouTube API, I get these errors in namespace
using Google.Apis.YouTube.v3;
using Google.Apis.YouTube.v3.Data;
Error 1 The type or namespace name 'v3' does not exist in the
namespace 'Google.Apis.YouTube' (are you missing an assembly
reference?)
Error 2 The type or namespace name 'v3' does not exist in the
namespace 'Google.Apis.YouTube' (are you missing an assembly
reference?)
it seems these "v3" tags does not exist so please help me
In order to make sure you have the correct libraries and dependencies, try downloading the Google.Apis.YouTube.v3 Client Library through NuGet. Here is what you do:
and then enter Install-Package Google.Apis.YouTube.v3 into the console and press enter. You should see something like this:
After the install completes, the references should have been added to the project that you have open and all you need to do is add your using statements:
using Google.Apis.YouTube.v3;
using Google.Apis.YouTube.v3.Data;

Web API not being recognized on my machine

I've pulled down a project onto my my machine that is using Web API. When I look at the nugget window it shows that I have web api 2.2, the web host, the core libraries, the client libraries, the cross origin support, and Data v 1-3.
However, when I try to build the project, I'm given the following errors:
The type or namespace name 'Cors' does not exist in the namespace 'System.Web.Http' (are you missing an assembly reference?)
and
The type or namespace name 'HttpApplication' does not exist in the namespace 'System.Web' (are you missing an assembly reference?)
Any help you guys and gals can give will be appreciated.
I've had the same issue after I had Resharper add the CORS reference.
I fixed it by adding the correct nuget packages: Microsoft.AspNet.Cors and Microsoft.AspNet.WebApi.Cors.

BING API, missing directive or an assembly

I have download the new Bing API C# file and added it to my ASP.NET web site, it works perfectly if uses ASP.NET MVC 2.0 but with simple ASP.NET website it shows an error on this line:
var bingContainer = new Bing.BingSearchContainer(new Uri("https://api.datamarket.azure.com/Bing/Search/"));
The error is:
Error 1
The type or namespace name 'Bing' could not be found (are you
missing a using directive or an assembly
reference?)
c:\Users\jawad\documents\visual studio 2010\WebSites\BingAPI\Default.aspx.cs
Any idea what I am missing?
1) Verify you have the correct using statement for the API.
2) Verify the API is referenced properly.
3) Verify that your project and the bing api project (or .dll) both have the same .net version selected.

Credentials for Webservices

I wanted to write credential for web services (I am using-VS 2008,Asp.Net Framework 3.5,Windows 2003 Standard Edition,SQL Server) like this
private Credentials credentials;
But i am getting error to this line that the type or namespace name 'Credentials' could not be found (are you missing a using directive or an assembly reference?)
I have used
using ExtentrixWS;
Still i am getting 'are you missing a using directive or an assembly reference?'
Regards,
You should not only add the "using ExtentrixWS" but also you should add the relavent dll to the references of the project. Then only the services of ExtentrixWS will be referrenced to your project.

Unable to access List using web reference in Sharepoint

I want to develop an application in C# which can access sharepoint data without any dependency to Windows Server Machine (Without using sharepoint dll). After adding reference to project I am unable to use this reference.
For example Web Reference name is: "MyServer". I am unable to use:
MyServer.Lists listService = new MyServer.Lists();
Showing error :
The type or namespace name 'MyServer' could not be found (are you missing a using directive or an assembly reference?)
How can i resolve this problem?
I think, the problem is that you have added a "service reference", not a SOAP web service web reference (see this article: http://alexduggleby.com/2008/08/24/add-web-reference-instead-of-service-reference-in-visual-studio-2008/)

Categories