Exchange Cannot Be Autodiscovered From Sharepoint?
Jan 25, 2011
I've created an ascx control for use in Sharepoint that accesses Exchange 2010 via it's web services. When run in it's own ASP.NET test site (wrapped in a simple aspx page) all works fine. As soon as the control is used within Sharepoint a "The Autodiscover service couldn't be located" error is encountered.
The code behind dll for the ascx control has been dropped in to the GAC and also Microsoft.Exchange.WebServices.dll
Microsoft.Exchange.WebServices.dll has also been added to the safe control list in web.config for the sharepoint site:
<SafeControl Assembly="Microsoft.Exchange.WebServices, Version=14.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" Namespace="Microsoft.Exchange.WebServices" TypeName="*" Safe="True" />
I can ping the autodiscovery service and access the Exchange web service url https://mydomain.com/EWS/Services.wsdl from the Sharepoint server.
A username and password is being sent to the service in the ascx's code behind:
Dim service As ExchangeService = New ExchangeService()
service.Credentials = New WebCredentials(usrExchange, pwdExchange)
service.ImpersonatedUserId = New ImpersonatedUserId(ConnectingIdType.SmtpAddress, email)
Interestingly, if I specify the url [URL] to the service I get a 405 Method not allowed error.
View 1 Replies
Similar Messages:
Jan 12, 2011
I have deployed a custom SharePoint Web service on Farm A. I am trying to access this Web service from a SharePoint timer job on Farm B. On Farm B, I am creating Class Library project, packaging it (wsp) and then deploying to GAC. The problem is I'm unable to access the Web Service using the following code. TodaysNewSVC is a service reference
TodaysNewSVC.GetTodaysnewsfromInsite objGetNews = new TodaysNewSVC.GetTodaysnewsfromInsite();
objGetNews.PreAuthenticate = true;
objGetNews.Credentials = CredentialCache.DefaultCredentials;
objGetNews.Url = "http://insite-dev.portal/_vti_bin/todaysnews.asmx";
DataTable dt2 = objGetNews.getNewsFromInsite(true, true);
//getNewsFromInsite is a WebMethod which returns the DataTable.
Note: Both farms use the same active directory authentication. I have also done the debugging for Timer Job and feature activation and they are working fine. The problem occurs during the call i.e. getNewsFromInsite
The asmx and wsdl files are accessible from Internet Explorer and also from Windows Console application. Here is the code which I use from console application:
GetTodaysnewsfromInsiteSoapClient objWSClient = new GetTodaysnewsfromInsiteSoapClient();
objWSClient.ClientCredentials.Windows.ClientCredential = System.Net.CredentialCache.DefaultNetworkCredentials;[code]...
Here is the error message:The request failed with the error message:
--
<html><head><title>Object moved</title></head><body>
<h2>Object moved to <a href="%2fPages%2fproblem-with-page.aspx%3fc%3d500">here</a>.</h2>
</body></html>
View 1 Replies
Jun 15, 2010
Following error comes when creating a WebPart In sharePoint 2010 Server.
Web Part Error: Unhandled exception was thrown by the user code wrapper's Execute method in the partial trust app domain: System.Web.HttpUnhandledException: Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> System.TypeLoadException: Could not load type 'Microsoft.SharePoint.WebControls.SPGridView' from assembly 'Microsoft.SharePoint, Version=14.900.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c'. at ListMenuSample.ListMenuSample.ListMenuSample.CreateChildControls() at System.Web.UI.Control.EnsureChildControls() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) --- End of inner exception stack trace --- at System.Web.UI.Page.HandleError(Exception e) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest() at System.Web.UI.Page.ProcessRequest(HttpContext context) at Microsoft.SharePoint.UserCode.SPUserCodeWebPartWrapper.ExecuteHttpRequest(SPUserCodeWebPartHttpRequestContext webPartExecutionContext, SPUserCodeWebPartHttpResponse httpRequestResponse) at Microsoft.SharePoint.UserCode.SPUserCodeWebPartWrapper.Execute(SPUserCodeExecutionContext executionContext) at Microsoft.SharePoint.UserCode.SPUserCodeApplicationHostAppDomainRef.Execute(Type userCodeWrapperType, SPUserCodeCachedAssemblyGroup userAssemblyGroup, Guid siteCollectionId, Byte[] binaryUserCodeToken, Byte[] proxyOperationToken, SPUserCodeExecutionContext executionContext)
View 1 Replies
Jan 9, 2010
Inside my ASP.NET application, I would like to add an iframe where I can display the emails from our exchange server for the logged in user. The web application uses forms authentication with custom authentication (passwords are hashed and stored in db).
Is there a way to show OWA within my web app without prompting the user for password (OWA uses windows authentication)? Can I use impersonation in some fashion or establish a trust between my IIS server and the server running OWA?
View 2 Replies
Aug 5, 2010
i have railway waiting list table and confirm table... i wanna query for waiting list passenger status if confirm.. passenger detail move from waiting list table to confirm table...
View 1 Replies
Jan 14, 2011
I am using this code to connect to my exchange server using POP3.I am trying to retrieve an inbox of basically emails that have not been read however, i am just getting a bunch of gibberish and its reading an email. modify my code to just read the most recent messages.
Try
tcpClient.Connect(hostName, 110)
Dim networkStream As NetworkStream = tcpClient.GetStream()[code]...
when i use top instead of retr i get this
+OK X-MimeOLE: Produced By Microsoft Exchange V6.5 Received: by xch0p.com id <01CB58CE.A6A4EA@p.com>; Mon, 20 Sep 2010 09:17:07 -0500 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01CB58CE.81A6A4EA" Content-class: urn:content-classes:message Subject: What we need to do?? Date: Mon, 20 Sep 2010 09:17:07 -0500 Message-ID:
View 3 Replies
May 25, 2010
We have a series of sites that run in on an outside server but currently to send email everything is routing through our local inhouse exchange server. We are looking to move our exchange to a ofsite exchange service, but don't want the emails from our apps to route to it for sending. I have seen some third party add ons that will allow you to send email with the smtp but not route through exchange. Does anyone have any experience with doing this? If so what would you suggest. Just looking for a way that we can send mail with out routing back through our servers.
View 1 Replies
Mar 11, 2010
I have defined two endpoints in my App.Config file as
[code]....
I received the following error when i try to launch the host
The HttpGetEnabled property of ServiceMetadataBehavior is set to true and the HttpGetUrl property is a relative address, but there is no http base address. Either supply an http base address or set HttpGetUrl to an absolute address.
How to fix it?
View 1 Replies
Jan 27, 2010
I have a dynamic table in my view. The table is used to enter data about items, the number for which is not known. The the user can add any number of rows to the table. The script is plain javascript.
Questions:
1. Right now a normal textbox and dropdown is added to each row using the javascript. How can I add a html helper control instead so that I can get the viewdata values.
2. The model contains a List<T> as a property. So, the dropdown control id is named as an array. Eg: item[0].type, item[1].typeThe problem is this dropdown is populated by data from viewdata. How can I add the data for an array thru viewdata. Remember the number of items is not known
View 1 Replies
Feb 4, 2010
I have a requirement to develop an application that read's email' from a "drop zone" and then populate a database.I can currently read from a default inbox on Exchange, and for now this is fine.But the long term goal is to have all email's sent to a drop zone to read from.Is it possible to have email's sent to a dropzone, getting rid of the need for Exchange?How can I choose a different inbox to read from on Exchange?
View 1 Replies
Jan 4, 2011
I'm beginner at C#, asp.net and I took a course about databases (fundamentals of Databases) I wouldn't ask such question because:
The thing I am required to do is an e-commerce project (small one) and I am stuck after connecting the database from SQL Server to Visual Studio using server explorer?
How in a simple manner can I send SQL queries and retrieve data and display it?
The problem is I have asked this while they know we didn't take web programming courses and I have to deliver the project next week (e-shopping cart + registration + signing in) !!!!
View 3 Replies
Apr 9, 2010
I have a service account SvcAcc to manage contacts (add/update/delete contacts) for all the exchange users. I Impersonate using the below cmdlet to manage contacts but it also allows SvcAcc to perform other functions (such as send email etc) on behalf of the user.
cmdlet
New-ManagementRoleAssignment -Name:impersonationAssignmentName -Role:ApplicationImpersonation -User:serviceAccount
//impersonation code
service.Credentials = new NetworkCredential(ServiceAccountUserName, ServiceAccountPassword, domain);
service.ImpersonatedUserId = new ImpersonatedUserId(ConnectingIdType.SmtpAddress, userEmail);
View 3 Replies
Jan 20, 2011
I have a situation where we are splitting dynamic content from static content and each is getting its own web server. The people maintaining the site want to be able to make navigation changes once and have it show on both servers without any major extra work (for them). I'm putting the navigation structure in an XML file which also has information on things specific to each content page. This brings me to the question of how to share that file. If I want the change to be instantaneous I can't rely on a scheduled task to copy the file from one server to another.Access to one of the servers is very limited due to security policy.
I am thinking about maybe a web service running on one server to get the data from it to pages on the other server. Does this sound viable or do any of you have other ideas that may work better? I considered having the navigation in a database but this introduces the need for a tool for the navigation updaters to have for them to do that. It is easy for them to update XML and just publish to the server with a lower security level. To get them database access requires terrible paperwork and meeting with security people.
View 5 Replies
Aug 3, 2010
I have been given a task to write a program to automatically create a 2010 exchange mailbox. My research tells me to use powershell but I can't seem to find the namespace to reference and would like some sample code. I found some code on the web but I don't know what the namespace is for PowerShell. I think it might be System.Management.Automation but when I try to reference the namespace it does not exist in the list of dotnet. All I have is System.Management and System.Management.Instrumentation.
View 2 Replies
Sep 14, 2010
I have the following code to store session variable in one webmethod and retrieve it in other webmethod but the value displays null when i try to retrieve it.
[WebMethod(EnableSession = true)]
[ScriptMethod(ResponseFormat = ResponseFormat.Json)]
public bool SubmitList1(string businessname )
{
Session["Company_Name"] = businessname;
SqlConnection con = new SqlConnection();
.......
.........
.........
}
This will be my second webmethod where i am trying to retrieve the session variable
[WebMethod(EnableSession = true)]
[ScriptMethod(ResponseFormat = ResponseFormat.Json)]
public bool addresslisting()
{
string companyname = (string)Session["Company_Name"];// this particular value is displaying null
......
........
}
View 2 Replies
Jan 14, 2010
i am building an intranet for the company and i when a ticket is raised i want to select a person and send them that ticket. I have the gridview in place and the users email address. All i need is some simplle send mail code in c# to get it going. I am not sure on what i have to do weather i have to authenticate it and if the fact that exchange is on a sbs 2008 server called server01 and the intranet is on server02 they are both on the same domain.
View 18 Replies
Sep 15, 2010
I do not want to set up a smtp server for mail sending.
I want to use existing exchange server.
How can i send an e-mail over exchange server?
Is there sample c# code?
View 5 Replies
Jun 26, 2012
I want to extract emails that are currently being sent to an exchange Server. I want to extract the emails and then take some actions based on their content.
View 7 Replies
Jul 26, 2010
I am trying to use System.Net.Mail SMTPClient to send emails. I have the sample code from MSDN:
[Code]....
What is the host name? I want to send emails using Exchange Online which I think the host is "red001.mail.microsoftonline.com"?
View 2 Replies
Apr 27, 2010
I want to read emails from exchange server 2007 using C# in my webform.
View 1 Replies
Aug 19, 2010
I am trying to send an email using an exchange smtp authentication. I have set the username, password, and domain and converted them to base 64 but I get an error message:-
Mailbox unavailable. The server response was: 5.7.1 Unable to relay
I have been trying to get this to work for months now and just can't seem to find the answer.
View 19 Replies
Mar 11, 2011
I have a few friends that I swap videos with and I am to design a meeting request form. The form should allow me to enter the contact details, the details of these friends I am swapping with and a suggested date and time to meet for the exchange. How do I go about this code.
View 5 Replies
Dec 27, 2010
I am building an stock exchange sort of application. I would like to know Is it possible to create graphs using crystal reports or is there any other technology in .NET for building a graph which we usually see in stock exchange application.
View 1 Replies
Jun 1, 2010
how to Read mails for a mailbox in Exchange server 2003 enviorment. For Eg, if a user send an email to a mailbox, the values in the subject line and the body of the message should be updated to a database (SQL 2005). I am using .NET framework 2 and C# laungage.
View 3 Replies
Jul 20, 2010
I have mailboxes in the exchange server and i need to copy the mailboxes data from the exchange server and place it to the other exchange server using c#.Is it possible to access the exchange server using c#.
View 1 Replies