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


Top 5 Contributors of the Month
Easy Web
Imran Ghani
Post New Web Links

connect to sharepoint site from c# console application

Posted By:      Posted Date: May 22, 2011    Points: 0   Category :C#
 

HI

I am .net developer and dont know about sharepoint.

I am developing a console application (c#) which has to connect to remote sharepoint server and download excel files from there. Currently the sharepoint site is hosted in development machine. So I am able to connect. But when I connect to a remote server its not allowing to connect. So is there anyway to connect to remote sharepoint site and download files using the site username and password

Thanks & regards

 


Thanks & Regards


View Complete Post


More Related Resource Links

SharePoint Application and Site Pages - Part 1 of 2

  
In this first part of the two part series, Steven covers the differences between Site and Application pages in SharePoint 2007, why each may be used in various circumstances, and prepares for the construction of a menu located application page. After a brief introduction he examines the concept of Site Pages and Application Pages separately in detail with supported screenshots.

SharePoint Application and Site Pages - Part 2 of 2

  
As the second article in a two part series, Steven examines the attributes and details of a SharePoint 2007 application page, including the construction and feature deployment of the same page based project. Since this is a WSS level objective, as opposed to MOSS, you will not need MOSS to work with the code included in this project. Windows Server 2003, WSS, and Visual Studio 2005 are all that is needed, with no additional add-ons. He provides a detailed analysis of each step involved in the creation and deployment of the project.

Unable to connect Oracle UCM Secured site with .NET Application

  
Hi, I am working on an integration of a .NET application which calls Oracle UCM web services which does Search, checkin of files to Oracle UCM( Stellent). Here i have an option to connect to a secured Oracle UCM server with credentials which retrieves the result. Here i am facing a problem. When we send a (https://) request we are getting an error as shown below: The underlying connection was closed: An unexpected error occured on a send. We are unable to do any code change on web services code as we have only the wsdl files. Tried Timeout related procedures which didnt work out. One more thing noticed is the .NET program connect to a http:// web url but not to https://. Is this a https:// issue with .NET application?   Kindly help with any inputs      

Unable to connect Oracle UCM Secured site with .NET Application

  
Hi, I am working on an integration of a .NET application which calls Oracle UCM web services which does Search, checkin of files to Oracle UCM( Stellent). Here i have an option to connect to a secured Oracle UCM server with credentials which retrieves the result. Here i am facing a problem. When we send a (https://) request we are getting an error as shown below: The underlying connection was closed: An unexpected error occured on a send. We are unable to do any code change on web services code as we have only the wsdl files. Tried Timeout related procedures which didnt work out. One more thing noticed is the .NET program connect to a http:// web url but not to https://. Is this a https:// issue with .NET application?   Kindly help with any inputs      

I get the "FilenotfoundExceptionunhandled" ? in Console application while displaying the SharePoint

  
Error Details: The Web application at http://dev001aaamaaind:333/ could not be found. Verify that you have typed the URL correctly. If the URL should be serving existing content, the system administrator may need to add a new request URL mapping to the intended application. string urlSite = "http://dev001aaamaaind:333/";         using (SPSite sc = new SPSite(urlSite))//Getting Error in the line        {            SPWeb site = sc.RootWeb;            foreach (SPList list in site.Lists)            {                if (!list.Hidden)                    Console.WriteLine(list.Title);            }        }

Unable To Connect Database Error:Sharepoint 2007 Internet Site.

  
Hi Techies,  we are running 4farm Sharepoint internet site. now a days we are getting the below error very regularly. Event Viewer :The description for Event ID ( 27745 ) in Source ( Windows SharePoint Services 3 ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer. You may be able to use the /AUXSOURCE= flag to retrieve this description; see Help and Support for details. The following information is part of the event: #50071: Unable to connect to the database SharePoint_Config on SPPREPROD02VMDK\SPPREDPROD.  Check the database connection information and make sure that the database server is running.. Sharepoint Logs:#50071 :#50071: Unable to connect to the database SharePoint_Config on pfc-penndb-tst. Check the database connection information and make sure that the database server is running.. Please Advice . Regards, raju.  Nag: http://nagaraju-sharepoint.blogspot.com. Posting is provided with no warranties.

Cannot connect SharePoint 2010 site with Office 2010 beta

  
I installed Office 2010 beta, then want to new a workspace of SharePoint 2010 beta. An error pop-up: SharePoint workspace cannot sync with the specified SharePoint site because its server version is not supported.My SharePoint 2010 beta is the only web front end server in a farm environment. I started all the SharePoint related services, but the error pop-up anyway...

How to connect 2 Lists Sharepoint site through Designer

  
Hello to all I am siddiqali new to sharepoint 2010,I want to know how can i connect 2 lists in sharepoint 2010 without using code ,look ups and visual webpart. I am guessing that it can be posibble through designer,but as i am new to sharepoint i am not able to do it  Example If in 1 list student number,name,class,section is existed ,In other list if we enter student number in text box we should get the student information   Thank You, MD.SIDDIQALI

cannot connect to sharepoint server intranet site through VPN with windows vista home premium 64bit

  
Hi, a company i work for has an intranet site using sharepoint 2008. i can connect to the intranet remotely through their vpn however i am not able to view the instranet site or ping the server it is on...

does anyone have any ideas on whether this might be a vista issue or ????

thanks,
jonathan

Executing SharePoint console application without sharing user credentials

  

I have a console application, which uses SharePoint object model to do some business operation, therefore it has been deployed on SharePoint server. Without sharing username/pwd, earlier we allow several users to access this console application by providing remote desktop file (.rdp) file. This .rdp file (ver5.1) contains username and encrypted password. With recent version 6.0 of .rdp, it still prompts for password. You may argue that it is due to security constraint.

What is the best approach to allow more users to run this console application without sharing user credentials, without modifying the console application.

Thanks in advance

 

J Justin

 


When i Add service Reference in console application, I was not able to connect the page?

  

Hi,

when i  add http://abcdef/webservice.svc in service reference , I got the following errors

"

The document at the url http://staging.syncfusion.com/SyncfusionService/WebsiteService.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 'http://26128-staging/SyncfusionService/WebsiteService.svc?disco'.'.
  - The remote name could not be resolved: '26128-staging'
- Report from 'http://staging.syncfusion.com/SyncfusionService/WebsiteService.svc' 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').'.
- Report from 'XML Schema' 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://staging.syncfusion.com/SyncfusionService/WebsiteService.svc'.
The remote server returned an unexpected response: (417) Expectation failed.
The remote server returned an error: (417) Expectation failed.
If the service is defined in the current solution, try building the solution and adding the service

SharePoint 2010 Service Application Proxy & My Site Settings

  

I have a SharePoint 2010 Site Configured with Claims based FBA. I have also made My Site work with FBA.

My question is:

In 2007 I would create a seperate SSP for FBA based my site and Set all configuration there. As SharePoint 2010 supports Service Application Proxy how can I isolate FBA based My site and Other AD sites.

While I was able to select the required services for my Site using Configure service application associations link in Central admin, all changes I make in My Site Settings reflect for both FBA & AD based application.

How do I isolate My Site changes ?? I wanted to have different configuration for each of the My Sites


[MOSS 2007] Cannot connect to SSL web application / site list

  


Hi all
I have a quite strange problem with MOSS 2007 and I cannot solve it..

I installed MOSS 2007 SP2 on a single server (Windows 2003 Server SP2 + local SQL Server 2005 Standard Edition) without problems

I created a web application (port 80) and a site list on it without problems; everything is running correctly, I can connect to http://servername and to http://servername/sites/sitename

Then I created a SSL web application (port 443) selecting "Use Secure Socket Layer"; web application is created without errors
I created a new site list on this web application and site list creation is correct

BUT I cannot connect (from the server) to https://servername/sites/sitename or to https://servername
I always have "Internet Explorer cannot display the webpage" error

I can connect to any other SSL website using the same Internet Explorer so I don't think it is a browser problem...

I cannot understand what is the problem; the strange thing is that some months ago I installed another server with the same configuration (web appl on port 80 and web appl on port 443 and sites created on ssl web app) and I had no problem and it is still perf

Convert ASP.NET Application to Sharepoint 2010 Site best way?

  

 Before I joined to my team they was completed ASP.Net Application for E-Services provided to public users on internet, but our customer ask for integration with SharePoint 2010 portal for both authentication and look and feel wise.

I want to know what best way to convert ASP.Net Application to SharePoint 2010 Site?


How to connect to remote desktop from console application?

  

Hello,

I'm trying to connect to remote desktop from console application without opening window using this code:

MsRdpClient7Class rdp = new MsRdpClient7Class();

rdp.Server = "11.1.111.11";
rdp.UserName = @"username";
rdp.AdvancedSettings2.ClearTextPassword = "password";

rdp.Connect();

But, there's an error message:

Error 1 Interop type 'MSTSCLib.MsRdpClient7Class' cannot be embedded. Use the applicable interface instead. C:\gtk\GetRemoteDesktop\ConsoleRemoteDesktop\Program.cs 16 7 ConsoleRemoteDesktop

How to accomplish it?

Thank you in advance.

Goran

 


Sharepoint Workspaces will not connect to Sharepoint 2010 site

  
I recieve a

CSI error 139
Hresult 80004005
Groove.exe

When I try to add my 2010 site to Sharepoint 2010 workspace

I have deleted site
I have repaired office 2010

Tried this on two different computers same error

Thank you

Linq to SharePoint - connect to specific site collection

  

I have a site collection at http://[server]:[port]/sites/[name].  When I try to execute a linq query I get an exception saying that the web at http://[server]:[port]/sites/[name] cannot be found.  If I pass http://[server]:[port] to the datacontext that web is found, but the SPList I am trying to query cannot be found.

From looking online I know you cannot (without workarounds) query cross site collections, but I don't want to do that.  How do I connect to the specific site collection at http://[server]:[port]/sites/[name] with linq to sharepoint?

Need to add that I am using linq to sharepoint in an aspx web app that is running on the SharePoint server.

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