Quantcast
Channel: Exchange Server Development forum
Viewing all 7132 articles
Browse latest View live

Accessing Extended properties added throug EWS in O365 mail box

$
0
0

Hi ,

I have requirement to access the O365 mails and read its content and set O365 to set a flag to process if further in the next step.

For the above i have used EWS and i was able to access the mail and move it to particular folder by assigning it a extended property. I will be using this extended property for next process. The extended property is getting set and the next process is using it .

My question here is i want to view this extended property in UI of mail box which i will be accessing through web. Is there any way i can access the extended properties through and modify them in UI and save.

Help will be much appreciated.

THanks!!


ALtaf Ali


Forward to external contact

$
0
0

What I thought would be a relatively simple process is turning out to be not so easy. We have a large number of created contacts, with assigned external email addresses. However, when I select an internal mailbox, go to mail flow, and try to forward the email to any contact, none of them show up. Only internal users show up in the selection list. I can manage these with our Exchange 2007 server, but our 2013 server seems inacapable of listing anything other than internal users. 

Is there something disabled or turned off, which prohibits the use of contacts?

Accessing Extended properties added throug EWS in O365 mail box

$
0
0

Hi ,

I have requirement to access the O365 mails and read its content and set O365 to set a flag to process if further in the next step.

For the above i have used EWS and i was able to access the mail and move it to particular folder by assigning it a extended property. I will be using this extended property for next process. The extended property is getting set and the next process is using it .

My question here is i want to view this extended property in UI of mail box which i will be accessing through web. Is there any way i can access the extended properties through and modify them in UI and save.

Help will be much appreciated.

THanks!!

Regards,

Altaf.


ALtaf Ali

[E2003] [Windows/Web] -- Trouble authenticating web applications to exchange server 2003 to send mail

$
0
0

Hello:

I posted this in the wrong forum initially (oops!) and the moderator moved it, then upon reflection thought here would be a better place for my question but did not have the power to move it, so rather than seam like a cross-posting disrespectful nobody,  I'll provide a link to the original post.  So sorry for the inconvenience!

Link: https://social.technet.microsoft.com/Forums/en-US/33b6a17f-abea-40a0-9c23-9e5f45024cd5/issues-authenticating-against-exchange-2003?forum=exchangesvrgenerallegacy

Apps are:

Invision Power Board V. 3.4.7 running on win2k3 enterprise IIS with a MySQL DB.  a forum application, blog hosting, image gallery, etc. platform

and Atlassian Confluence 4.1 on the same box using its own built-in database something like H2 or some such as my lab is simply a test bench.


Could not send e-mail because address has ".@"

$
0
0

Hello!

I have a problem with the exchange server because when I want to send an e-mail that has this combination ".@" it gives the following error: "one or more recipients are invalid" and that is NOT true. There is any possibility to solve the regular expresion that verify the format of an e-mail address?

Gmails users are allow to choose that combination for an e-mail address and is impossible send an e-mail throw an exchange server.

Thanks in advance.

Using EWS API in Orchestrator

$
0
0

Hi

I need to use the EWS API from System Center Orchestrator. I have made a simple script to logon to a mailbox using impersonation. The script runs fine from Powershell ISE on the Orchestrator machine. But when I paste the code on a .net activity (powershell) I get the following error:

Exception calling "Bind" with "2" argument(s): "The request failed. The remote server returned an error: (401) Unauthorized."

This is the code:

## Define UPN of the Account that has impersonation rights
$AccountWithImpersonationRights = "admin@contoso.com"
##Define the SMTP Address of the mailbox to impersonate
$MailboxToImpersonate = "user@contoso.com"

## Load Exchange web services DLL
$dllpath = "C:\Program Files\Microsoft\Exchange\Web Services\2.0\Microsoft.Exchange.WebServices.dll"
Import-Module $dllpath

## Set Exchange Version
$ExchangeVersion = [Microsoft.Exchange.WebServices.Data.ExchangeVersion]::Exchange2013_SP1

## Create Exchange Service Object
$service = New-Object Microsoft.Exchange.WebServices.Data.ExchangeService($ExchangeVersion) 

$KeyFile = "c:\sistemas\scripts\securestrings\AES.key"
$Key = Get-Content $KeyFile
$PasswordFile = "c:\sistemas\scripts\securestrings\admin_AES.txt"
$secpasswd = Get-Content $PasswordFile | ConvertTo-SecureString -Key $key
$creds = New-Object System.Net.NetworkCredential("contoso\admin",$secpasswd) 

$service.Credentials = $creds 

# Change the URL to point to your cas server
$service.Url= new-object Uri("https://owa.contoso.com/EWS/Exchange.asmx")

##Login to Mailbox with Impersonation

$service.ImpersonatedUserId = New-Object Microsoft.Exchange.WebServices.Data.ImpersonatedUserId([Microsoft.Exchange.WebServices.Data.ConnectingIdType]::SmtpAddress,$MailboxToImpersonate ); 

#Connect to the Inbox and display basic statistics
$InboxFolder= new-object Microsoft.Exchange.WebServices.Data.FolderId([Microsoft.Exchange.WebServices.Data.WellKnownFolderName]::Inbox,$ImpersonatedMailboxName) 
$Inbox = [Microsoft.Exchange.WebServices.Data.Folder]::Bind($service,$InboxFolder)

$ArchiveFolder= new-object Microsoft.Exchange.WebServices.Data.FolderId([Microsoft.Exchange.WebServices.Data.WellKnownFolderName]::ArchiveMsgFolderRoot,$ImpersonatedMailboxName) 
$Archive = [Microsoft.Exchange.WebServices.Data.Folder]::Bind($service,$ArchiveFolder)


Cannot bind to DiscoveryHolds items in PublicFolders with "An internal server error occurred. The operation failed"

$
0
0

Environment: Exchange Server 2016, EWS Managed API 2.2

I'm developing a custom solution that collects emails from system folders of users mailboxes (Versions, DiscoveryHolds, Deletions, Purges) and PublicFolders mailboxes (DUMPSTER_ROOT, DiscoveryHolds)

But for some reason I cannot bind to DiscoveryHolds items in PublicFolders mailbox (\NON_IPM_SUBTREE\DiscoveryHolds) with "An internal server error occurred. The operation failed"

Here is an example of code and error when executing FindItems:

var pfFolder = Folder.Bind(service, WellKnownFolderName.PublicFoldersRoot); var rootFolder = Folder.Bind(service, pffolder.ParentFolderId); // bind to DiscoveryHolds by "rootFolder/NON_IPM_SUBTREE/DiscoveryHolds" path discoveryHolds.FindItems(new ItemView(int.MaxValue) { PropertySet = new PropertySet(BasePropertySet.IdOnly) };

...

2015-12-25 16:22:00,321 DEBUG [RR.UdpTraceReceiver] - Microsoft.Exchange.WebServices.Data.ServiceResponseException: An internal server error occurred. The operation failed.
   at Microsoft.Exchange.WebServices.Data.ServiceResponse.InternalThrowIfNecessary()
   at Microsoft.Exchange.WebServices.Data.MultiResponseServiceRequest`1.Execute()
   at Microsoft.Exchange.WebServices.Data.Folder.FindItems(ItemView view)
   at ExchangeExplorer.MainForm.tvFolders_AfterSelect(Object sender, TreeViewEventArgs e)

  


Here is an error from EWS logs (c:\Program Files\Microsoft\Exchange Server\V15\Logging\Ews\):

ExceptionHandler_Execute=Microsoft.Exchange.Data.Storage.NoReplicaHereException: Cannot query rows in a table. ---> Microsoft.Mapi.MapiExceptionNoReplicaHere: MapiExceptionNoReplicaHere: Unable to query table rows.   
 at Microsoft.Mapi.MapiExceptionHelper.InternalThrowIfErrorOrWarning(String message  Int32 hresult  Boolean allowWarnings  Int32 ec  DiagnosticContext diagCtx  Exception innerException)    
 at Microsoft.Mapi.MapiExceptionHelper.ThrowIfError(String message  Int32 hresult  IExInterface iUnknown  Exception innerException)    
 at Microsoft.Mapi.MapiTable.QueryRows(Int32 crows  QueryRowsFlags flags)    
 at Microsoft.Exchange.Data.Storage.QueryResult.Fetch(Int32 rowCount  QueryRowsFlags flags)    --- End of inner exception stack trace ---    
 at Microsoft.Exchange.Data.Storage.QueryResult.Fetch(Int32 rowCount  QueryRowsFlags flags)    
 at Microsoft.Exchange.Data.Storage.QueryResult.GetRows(Int32 rowCount  QueryRowsFlags flags  Boolean& mightBeMoreRows)    
 at Microsoft.Exchange.Services.Core.Search.NormalQueryView.CombineRPCViewData(IQueryResult queryResult  Int32 rowsToGet  BasePagingType pagingType  Boolean secureFolder)    
 at Microsoft.Exchange.Services.Core.Search.BasePagingType.ApplyPostQueryPaging(IQueryResult queryResult)    
 at Microsoft.Exchange.Services.Core.Search.NoGrouping.IssueQuery(QueryFilter query  Folder folder  SortBy[] sortBy  BasePagingType paging  ItemQueryTraversal traversal  PropertyDefinition[] propsToFetch  RequestDetailsLogger logger)    
 at Microsoft.Exchange.Services.Core.FindItem.FindItemsInParent(IdAndSession folderIdAndSession)    
 at Microsoft.Exchange.Services.Core.FindItem.Execute()    
 at Microsoft.Exchange.Services.Core.ExceptionHandler`1.Execute(CreateServiceResult createServiceResult  Int32 index  GenerateMessageXmlForServiceError generateErrorXml);ServiceDiagnostics_ReportException=Microsoft.Exchange.Data.Storage.NoReplicaHereException: Cannot query rows in a table.
 ---> Microsoft.Mapi.MapiExceptionNoReplicaHere: MapiExceptionNoReplicaHere: Unable to query table rows. 

Any help would be greatly appreciated,
Alexander




Corrupted Mailbox

$
0
0

Error Message:The Properties on this object have invalid data. if you have click Ok, default values will be used instead and will be saved if you don't change them before hitting Apply or Ok on the Property Page. If you Click Cancel. the Object Will Be displayed read-only and corrupted values will be retained.

How solved...


[E2007,E2010,E2013] [EWSMA] [C#] [Windows]: Group Expansion Not Working for Hidden Group?

$
0
0

Hi,

I have some code that is reading through mailboxes and extracting in-box, Sent Items and Deleted Items data. In relation to Sent Items I am particularly interested in identifying how many people the user sent emails to. Initial versions of the application just read the message.ToRecipients collection.  This gave me the individual email addresses the user sent emails tom but I need to be more accurate and also work out if the recipient is a group.  I inserted the MSDN example code for group expansion and this seemed to be working fine and I was getting the groups expanded out to their individual member email addresses. I have noticed however that we have a couple of groups that are hidden from the normal lists and these two do not expand.

When I checked the code I found that the address.MailboxType was coming back as null?

I then decided that I couldn't test for a group using:

if(message.ToRecipients[o].MailboxType == MailboxType.PublicGroup
    || message.ToRecipients[o].MailboxType == MailboxType.ContactGroup
    || message.ToRecipients[o].MailboxType == MailboxType.PublicFolder
    )

So although it's messy I would assume all email addresses being processed are groups and when I then try and expand it and get an error I therefore assume it is a single mail address.

This doesn't work either as the group still doesn't expand and throws the same error as a single mail address so to all intents and purposes it appears to all the World as though it is a single mail address.  Is this a bug in the EWS Managed API?

This is the full block of code:

                            //TO  ==============================================
                            if (message.ToRecipients == null || message.ToRecipients.Count == 0)
                            {
                                //Do nowt!
                            }
                            else
                            {
                                for (o = 0; o <= message.ToRecipients.Count - 1; o++)
                                {
                                    //Check for distribution group.
TryAgain2:
                                    NumRetries = 0;
                                    try
                                    {
                                        grp = service.ExpandGroup(message.ToRecipients[o].Address);
                                        if (grp.Members.Count> 0)
                                        {
                                            foreach (EmailAddress address in grp.Members)
                                            {
                                                EmailTo tr = new EmailTo();
                                                tr.ToEmailAddress = ConvertLEDN(address);
                                                if(paramCN==null)
                                                    tr.AddRecord(0,false, d.DataExtractTableID,ref cn);
                                                else
                                                    tr.AddRecord(0, false, d.DataExtractTableID, ref paramCN);
                                                tr.Dispose();
                                            }
                                        }
                                        else
                                        {
                                            EmailTo tr = new EmailTo();
                                            tr.ToEmailAddress = ConvertLEDN(message.ToRecipients[o].Address);
                                            if (paramCN == null)
                                                tr.AddRecord(0, false, d.DataExtractTableID, ref cn);
                                            else
                                                tr.AddRecord(0, false, d.DataExtractTableID, ref paramCN);
                                            tr.Dispose();
                                        }
                                    }
                                    catch (Exception ex)
                                    {
                                        if(ex.Message == "No results were found.")
                                        {
                                            EmailTo tr = new EmailTo();
                                            tr.ToEmailAddress = ConvertLEDN(message.ToRecipients[o].Address);
                                            if(paramCN == null)
                                                tr.AddRecord(0, false, d.DataExtractTableID, ref cn);
                                            else
                                                tr.AddRecord(0, false, d.DataExtractTableID, ref paramCN);
                                            tr.Dispose();
                                        }
                                        else
                                        {
                                            timer1.Enabled = true;
                                            int c = 0;
                                            do
                                            {
                                                c++;
                                                if (c % 1000 == 0)
                                                {
                                                    Application.DoEvents();
                                                }
                                            } while (TimeElapsed == false);
                                            timer1.Enabled = false;
                                            NumRetries++;
                                            if (NumRetries <= 20)
                                            {
                                                goto TryAgain2;
                                            }
                                            else
                                            {
                                                string msg = "Last error message was:" + Common.NNL + ex.Message + Common.NNL + "Press Yes to try again." + Common.NL + "Press No to save the data file and end the program.";
                                                PEH("GetMailData", "frmDataCollector", "Error in GetMailData Group Expansion in To Recipients with greater than 20 request failed errors, server may be offline?");
                                                if (MessageBox.Show(msg, Common.H, MessageBoxButtons.YesNo, MessageBoxIcon.Question, MessageBoxDefaultButton.Button1) == System.Windows.Forms.DialogResult.No)
                                                    Environment.Exit(0);
                                                else
                                                    goto TryAgain2;
                                            }
                                        } // if(ex.Message== "No results were found.")
                                    } // End of Catch block
 
                                }  // End of for (o = 0; o <= message.ToRecipients.Count - 1; o++)
                            } // End of if (message.ToRecipients == null || message.ToRecipients.Count == 0)

Siv


Graham Sivill - Martley, Worcester. UK


EWS C# : inline attachments not redering correctly

$
0
0

when sending mail messages to faxination using outlook api the inline (Signature images) are correctly embedded in the generated tif.

when doing the same with ews managed api, a separate page is created for each inline (image) attachment

Send mail task script to use exchange server

$
0
0

Hello!

I am looking into for solutions to send mail script task to send mails from SSIS from Azure VM using an exchange server that is on different physical location.

Can anyone shed some light?

Thanks in advance....

[Exchange-Online][EWS][SOAP] MeetingTimeZone TimeZoneName consisting of only � characters

$
0
0
We have a customer where several `GetItem` SOAP calls to Exchange Web Services return XML containing:

    <t:MeetingTimeZone TimeZoneName="&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;">

(32 null characters). Subsequently, my code code fails with an 'Invalid Unicode-character' EDOMParseError - of course.

The server version is:

    <h:ServerVersionInfo MajorVersion="15" MinorVersion="1" MajorBuildNumber="361" MinorBuildNumber="14" Version="V2015_10_05" xmlns:h="http://schemas.microsoft.com/exchange/services/2006/types" xmlns="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>

This is the online Exchange365.

What can be going on here? How can this weird TimeZoneName creep in? Can it be prevented?

FWIW, here is the full XML returned:

    <?xml version="1.0" encoding="UTF-8"?>
    <s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
      <s:Header>
        <h:ServerVersionInfo xmlns:h="http://schemas.microsoft.com/exchange/services/2006/types" xmlns="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" MajorVersion="15" MinorVersion="1" MajorBuildNumber="361" MinorBuildNumber="14" Version="V2015_10_05" />
      </s:Header>
      <s:Body>
        <m:GetItemResponse xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types">
          <m:ResponseMessages>
            <m:GetItemResponseMessage ResponseClass="Success">
              <m:ResponseCode>NoError</m:ResponseCode>
              <m:Items>
                <t:CalendarItem>
                  <t:ItemId Id="AQMkAG[snip]AAAA==" ChangeKey="DwAA[snip]pg28O" />
                  <t:ParentFolderId Id="AQMk[snip]AAAA==" ChangeKey="AQAAAA==" />
                  <t:ItemClass>IPM.Appointment</t:ItemClass>
                  <t:Subject>Daily Scrum</t:Subject>
                  <t:Sensitivity>Normal</t:Sensitivity>
                  <t:Body BodyType="Text">Something</t:Body>
                  <t:DateTimeReceived>2014-04-16T06:18:23Z</t:DateTimeReceived>
                  <t:Size>7972</t:Size>
                  <t:Importance>Normal</t:Importance>
                  <t:IsSubmitted>false</t:IsSubmitted>
                  <t:IsDraft>false</t:IsDraft>
                  <t:IsFromMe>false</t:IsFromMe>
                  <t:IsResend>false</t:IsResend>
                  <t:IsUnmodified>false</t:IsUnmodified>
                  <t:DateTimeSent>2014-04-16T06:18:23Z</t:DateTimeSent>
                  <t:DateTimeCreated>2014-04-16T06:17:40Z</t:DateTimeCreated>
                  <t:ResponseObjects>
                    <t:ForwardItem />
                  </t:ResponseObjects>
                  <t:ReminderDueBy>2015-12-21T08:15:00Z</t:ReminderDueBy>
                  <t:ReminderIsSet>true</t:ReminderIsSet>
                  <t:ReminderMinutesBeforeStart>0</t:ReminderMinutesBeforeStart>
                  <t:DisplayCc />
                  <t:DisplayTo />
                  <t:HasAttachments>false</t:HasAttachments>
                  <t:Culture>nl-NL</t:Culture>
                  <t:EffectiveRights>
                    <t:CreateAssociated>false</t:CreateAssociated>
                    <t:CreateContents>false</t:CreateContents>
                    <t:CreateHierarchy>false</t:CreateHierarchy>
                    <t:Delete>true</t:Delete>
                    <t:Modify>true</t:Modify>
                    <t:Read>true</t:Read>
                  </t:EffectiveRights>
                  <t:LastModifiedName>Mark de Waal</t:LastModifiedName>
                  <t:LastModifiedTime>2015-12-17T09:14:40Z</t:LastModifiedTime>
                  <t:UID>04000[snip]1A2FD6</t:UID>
                  <t:DateTimeStamp>2015-12-17T09:14:40Z</t:DateTimeStamp>
                  <t:Start>2015-06-10T07:15:00Z</t:Start>
                  <t:End>2015-06-10T07:30:00Z</t:End>
                  <t:IsAllDayEvent>false</t:IsAllDayEvent>
                  <t:LegacyFreeBusyStatus>Busy</t:LegacyFreeBusyStatus>
                  <t:IsMeeting>false</t:IsMeeting>
                  <t:IsCancelled>false</t:IsCancelled>
                  <t:IsRecurring>false</t:IsRecurring>
                  <t:MeetingRequestWasSent>false</t:MeetingRequestWasSent>
                  <t:IsResponseRequested>true</t:IsResponseRequested>
                  <t:CalendarItemType>RecurringMaster</t:CalendarItemType>
                  <t:MyResponseType>Unknown</t:MyResponseType>
                  <t:Organizer>
                    <t:Mailbox>
                      <t:Name>Mark de Waal</t:Name>
                      <t:EmailAddress>m.dewaal@isah.com</t:EmailAddress>
                      <t:RoutingType>SMTP</t:RoutingType>
                    </t:Mailbox>
                  </t:Organizer>
                  <t:Duration>PT15M</t:Duration>
                  <t:TimeZone />
                  <t:AppointmentSequenceNumber>0</t:AppointmentSequenceNumber>
                  <t:AppointmentState>0</t:AppointmentState>
                  <t:Recurrence>
                    <t:WeeklyRecurrence>
                      <t:Interval>1</t:Interval>
                      <t:DaysOfWeek>Monday Tuesday Wednesday Thursday</t:DaysOfWeek>
                    </t:WeeklyRecurrence>
                    <t:NoEndRecurrence>
                      <t:StartDate>2015-06-10+02:00</t:StartDate>
                    </t:NoEndRecurrence>
                  </t:Recurrence>
                  <t:FirstOccurrence>
                    <t:ItemId Id="AAMk[snip]AEA==" ChangeKey="DwAA[snip]pg28O" />
                    <t:Start>2015-06-10T07:15:00Z</t:Start>
                    <t:End>2015-06-10T07:30:00Z</t:End>
                    <t:OriginalStart>2015-06-10T07:15:00Z</t:OriginalStart>
                  </t:FirstOccurrence>
                  <t:MeetingTimeZone TimeZoneName="&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;&#x0;">
                    <t:BaseOffset>-PT60M</t:BaseOffset>
                    <t:Standard TimeZoneName="Standard">
                      <t:Offset>PT0M</t:Offset>
                      <t:RelativeYearlyRecurrence>
                        <t:DaysOfWeek>Sunday</t:DaysOfWeek>
                        <t:DayOfWeekIndex>Last</t:DayOfWeekIndex>
                        <t:Month>October</t:Month>
                      </t:RelativeYearlyRecurrence>
                      <t:Time>02:00:00</t:Time>
                    </t:Standard>
                    <t:Daylight TimeZoneName="Daylight">
                      <t:Offset>-PT60M</t:Offset>
                      <t:RelativeYearlyRecurrence>
                        <t:DaysOfWeek>Sunday</t:DaysOfWeek>
                        <t:DayOfWeekIndex>Last</t:DayOfWeekIndex>
                        <t:Month>March</t:Month>
                      </t:RelativeYearlyRecurrence>
                      <t:Time>03:00:00</t:Time>
                    </t:Daylight>
                  </t:MeetingTimeZone>
                  <t:ConferenceType>0</t:ConferenceType>
                  <t:IsOnlineMeeting>false</t:IsOnlineMeeting>
                  <t:NetShowUrl />
                </t:CalendarItem>
              </m:Items>
            </m:GetItemResponseMessage>
          </m:ResponseMessages>
        </m:GetItemResponse>
      </s:Body>
    </s:Envelope>
   

Version of Powershell...

$
0
0

hello,

As I am getting the error:

The specified snap-in 'Microsoft.Exchange.Management.PowerShell.Admin' failed to load.
No Windows PowerShell Snap-ins are available for version 1.

TestActiveSyncConnectivity  --> emgch1 to emgmb1
TestImapConnectivity  --> emgch2 to emgmb2

Problem Description
When writing .NET code which uses the System.Management.Automation namespace or using Windows
Powershell you may receive the following error when you attempt to load the Exchange Management
Shell snap-in.
"No Windows PowerShell Snap-ins are available for version 1"

Resolution
Exchange 2007 is only supported on 64-bit Windows and is, itself, a 64-bit application,
therefore many of the components including the shell extensions are 64-bit. 
On a 64 bit version of Windows with Powershell installed there are two versions of Powershell.exe.
  One is the 32-bit version (found at C:\WINNT\syswow64\windowspowershell\v1.0\powershell.exe)
and the other is the 64-bit version (found at C:\WINNT\system32\windowspowershell\v1.0\powershell.exe).
  The Exchange Management Shell snap-in will only load into the 64-bit Powershell.  If you try
to load it into the 32-bit Powershell.exe, you get the error message above.
Likewise, if you are automating Powershell from an application it must be compiled for 64-bit
in order to load the Exchange Management Shell snap-in.

%SystemRoot%\sysWOW64\WindowsPowerShell\v1.0\powershell.exe is the 32 Bits version
%SystemRoot%\system32\WindowsPowerShell\v1.0\powershell.exe is the 64 Bits version

I am working on a 64 Bits machine, I need to be sure the modules are compiled from C:\WINNT\system32\windowspowershell\v1.0\powershell.exe

How can I be sure of which version is compiled between 32 and 64?

Thanks,
Dom


Altiris Support / System Center Configuration Manager Support

Problem with SendOnlyToChanged

$
0
0

Hi

I tried to use EWS API 2.0 to remove an attendee from the exchange calendar meeting with option "SendOnlyToChanged". Removed attendee received an email with "cancel" the meeting but others attendees also received an email with update the meeting. I don't know why because I set SendOnlyToChanged option.

So every time when I removed attendee others received an meeting update.

My code:

ExchangeService service = new ExchangeService(ExchangeVersion.Exchange2010_SP2);
service.Credentials = CredentialCache.DefaultNetworkCredentials;
service.ImpersonatedUserId = new ImpersonatedUserId(ConnectingIdType.SmtpAddress,email@email);
service.AutodiscoverUrl("email@email");

String sEntryID = _szkolenie_item["outlook_calendar_item_id"].ToString();
String sEWSID = GetConvertedEWSID(service, sEntryID, "email@email");

Appointment _spotkanie = Appointment.Bind(service, new ItemId(sEWSID));
                                            
for (int i = 0; i < _spotkanie.RequiredAttendees.Count; i++)
{
if (_spotkanie.RequiredAttendees[i].Address.ToLower().Equals(getSPUser(_site2, _zapisy_item["uczestnik"].ToString()).Email.ToLower()))
{
_spotkanie.RequiredAttendees.RemoveAt(i);
break;
}
}
_spotkanie.Update(ConflictResolutionMode.AlwaysOverwrite, SendInvitationsOrCancellationsMode.SendOnlyToChanged);

 

 Anybody can explain why this happened and how to fix it ?


MNiemczycki

[E2010, E2013, Exchange Online][Javascript][Windows] : Need to Connect to Exchange using javascript

$
0
0

I am creating an application using nodeJS and javascript for achieving following functionalities:

  • Autodicover URL
  • Fetching calendar items
  • Get user availability details
  • Fetching contacts

Please let me know the recommended way of accessing exchange API using javascript. Can we use SOAP xmlHttpRequests to connect to exchange and fetch required details like contacts/calendar items. Also, Please let me know is there any javascript API. Any help would be highly appreciated.

Thanks,

Alka S


Authenticate an EWS application by using OAuth

[EX2016][TA] Data archiving and the Exchange 2016 transport architecture

$
0
0

Hi,

I'm a long time Outlook (addin) and Exchange (transport agent) developer and I'm still looking over / exploring the new architecture of 2016 and I have some concerns perhaps someone (perhaps from MS?) can advise on….

So looking at the new transport system architecture esp. within the categorizer I’m a little concerned that it will be easy for organisations (esp. those who rely on out-of-the-box Exchange 2016 journaling) to be in breach (by accident) of their data retention / archiving laws.

Unless you're grabbing email with a protocol / SMTP agent or have installed and prioritized a routing agent to be the very first agent in the chain then there’s a chance that messages archived may:

  • Not be seen in original format - This is a requirement by law in many countries but if content conversion has occurred before an agent gets a look at the message then what the agent is seeing is possiblynot the original message.
  •  May not be seen with the original recipient (or sender) details - Again, a requirement by law in many countries but if recipient resolution has taken place before an agent sees the message than the original sender and recipient list has possibly been changed (also … with bifurcation some messages may have been split so when looking for a message you could if not vigilant, find only part of the original recipient list).
  • Will not include all emails as some emails will have been removed by the new malware agent.

So this may not seem like much but if a law requires that a message must archived in "original format" with original sender (searchable i.e. as an index) and recipient values then I’m thinking some organisations won’t be compliant ??

It would be nice to see Microsoft provide an agent interface specifically for this i.e.a read-only look at all messages before any agents have had a chance to modify them – failing that, I think admins should be aware of that it may take work to be compliant with their data retention laws.

Thoughts ?


Scott Quinn | C# developer & messaging specialist (for hire). Contact me at http://au.linkedin.com/in/scottquinn


Old Account samayala01@live.com

$
0
0



I am having trouble download or loging in to my email account

my setup is windows vista sp2 and microsoft outlook

My live id is the above email

i HAVE TRIED LOGIN IN AS SIGNLE USER FOR OUTLOOK DESKTOP OR VISTA MAIL AND IT HAS TROUBLE WITH CERTIFICATION I DONOT HAVE A MAIL CERTIFICAT JUST COMPUTER AUTHORIZATION CERT W/ EMAIL

my emails addresses are sam13562@outlook or sam13562@hotmail one is what program calls alias

my other address si samcayala@outlook or samcayala@hotmail again one is alias

I was able to set it up with microsoft exchange option and i would have access to all my addresses IN ONE PLACE

I AM ABLE TO LOGIN THRU THE WEB , WITH EXPLORER; GOOGLE; FIREFOX,

MAPISession.LogOn() is working with Windows Form App but Fails in Windows Services on Windows Server 2008 R2

$
0
0


Hi,

I am working on a migration project. The old code was written VB.Net (.Net F/w 1.1). It is a Windows Service Application.

The purpose of the code in side the Windows Service App is to get an MAPI session using the code, so that we can read mails from the outlook using object cdoSession

            Dim cdoSession As MAPI.Session = New MAPI.Session
            cdoSession.Logon("epm_admin","Start123", True, True)
            Return cdoSession

This code was working while the Outlook version was 2007 and .net version was 1.1. and the code was called from an Windows Service for reading mails from outlook in a certain interval.

Now after migration , the server is Windows Server 2008 R2, .net f/w is 4.5 and Outlook is 2013. getting an error ([Collaboration Data Objects - [MAPI_E_UNKNOWN_FLAGS(80040106)])while encountering the code line:

cdoSession.Logon("epm_admin", "Start123", True, True) and the code is running as a Windows Service.

[THE SAME CODE IS WORKING FINE IF IT IS RUN WITH WINDOWS FORM APP)

PLEASE HELP SO THAT IT WILL RUN FROM WINDOWS SERVICE.

[E2010][EWSJA][JAVA] - SPNEGO Authentication

$
0
0

Exchange Version:Exchange2010 SP2
API Name: EWS Java Api
API Version:2.1-SNAPSHOT
IDE: Eclipse 3.6
Targeted features: Authentication
Scenario description: I've been working on a project wich uses SPNEGO to have Single Sign On for a Java based webapp running on a Websphere Application Server inside a Linux server. At the moment, it's working successfully and getting back the "LTPA" token if the browser has been configured properly. Next, i need to pass that user and token to the EWS as the authentication so i can access the remote user mailbox through the API.

I tried getting the token back from the request and using it within TokenCredentials:

ExchangeCredentials credentials = new TokenCredentials(ltpa2Token);
servicesetCredentials(credentials);

But this is the error:

<Trace Tag="EwsRequestHttpHeaders" Tid="161" Time="2016-01-07 14:26:03Z">
POST /ews/Exchange.asmx/wssecurity HTTP/1.1
User-Agent : ExchangeServicesClient/0.0.0.0
Keep-Alive : 300
Accept-Encoding : gzip,deflate
Accept : text/xml
Connection : Keep-Alive
Content-type : text/xml; charset=utf-8

</Trace>

<Trace Tag="EwsRequest" Tid="161" Time="2016-01-07 14:26:03Z">
<?xml version="1.0" encoding="UTF-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
   <soap:Header xmlns:wsa="http://www.w3.org/2005/08/addressing" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">
      <t:RequestServerVersion Version="Exchange2010_SP2" />
      &lt;wsa:Action soap:mustUnderstand='1'&gt;http://schemas.microsoft.com/exchange/services/2006/messages/Subscribe&lt;/wsa:Action&gt;&lt;wsa:ReplyTo&gt;&lt;wsa:Address&gt;http://www.w3.org/2005/08/addressing/anonymous&lt;/wsa:Address&gt;&lt;/wsa:ReplyTo&gt;&lt;wsa:To soap:mustUnderstand='1'&gt;https://exchange.ardp.local/ews/Exchange.asmx/wssecurity&lt;/wsa:To&gt;&lt;wsse:Security soap:mustUnderstand='1'&gt;  nullzLjb4ZnHM9y2O2Nk1bFWNcdEl+c4yYxFamVDsn4nLFYqnTaGhDNEqweKblV1uaU5NPfmY3B9LLw3n3gvx0jSyoXnQS9gkREiKeUaAp0SlUJvj2Lz343q0gOzycn2ukviGLnzq+5qg0mbkLNBJl10oqKRywd+Zhix1AYGz85w60cue6QniFhPpMbUygCBp+S7BLYr42+siP6rrvWVAT+K1khy/qmwBvqHwgiVHDC+BN581AEHjcjopAELx0dUiv8Rzv60HqISfkqvtiF1GQEoJlwl7XygAJVNo4nEPCUF+zPgjPO9ZtAHckVMQfYkD/aL5Hj8u7Fh7FfI6zSSQ6RFEI+bNC2DKX8sReMmIMWB8hbVFrj6gfe1rYn09Bh+nRzaa+xlFRGRff2Jntmu4UZ6c5/VA4nwfIL4p1bmylh74gMiV/6O4gsfux/Gm+ApRuvefhwzhU8q7YGk1Wr/jPE3lPudaE9rlbASj3e1dJDCEWGAPxzYDe6gWqXTZ5tB+xKH4yZaQOs5lDy4pZn4TLCj3yDYFbvW8uxF0LyNgiuhPqhJEVNyc0cqGkrMbnsin3tpu1fP0NLor8FdMD7kA8XBGA==&lt;/wsse:Security&gt;
   </soap:Header>
   <soap:Body>
      <m:Subscribe>
         <m:PushSubscriptionRequest SubscribeToAllFolders="true">
            <t:EventTypes>
               <t:EventType>ModifiedEvent</t:EventType>
            </t:EventTypes>
            <t:StatusFrequency>1</t:StatusFrequency>
            <t:URL>http://bualctp01:9080/intranet/rest/emailnotification/incomingevent</t:URL>
         </m:PushSubscriptionRequest>
      </m:Subscribe>
   </soap:Body>
</soap:Envelope></Trace>

microsoft.exchange.webservices.data.core.exception.service.remote.ServiceRequestException: The request failed. The request failed. Connection reset
        at microsoft.exchange.webservices.data.core.request.SimpleServiceRequestBase.internalExecute(SimpleServiceRequestBase.java:74)
        at microsoft.exchange.webservices.data.core.request.MultiResponseServiceRequest.execute(MultiResponseServiceRequest.java:158)
        at microsoft.exchange.webservices.data.core.ExchangeService.subscribeToPushNotificationsOnAllFolders(ExchangeService.java:2132)
        at com.icbc.intranet.integration.exchange.MSExchangeServiceManager.subscribeToPushNotifications(MSExchangeServiceManager.java:136)
        at com.icbc.intranet.integration.exchange.MSExchangeJavaStep.subscribeToPushNotifications(MSExchangeJavaStep.java:187)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
        at java.lang.reflect.Method.invoke(Method.java:611)
        at com.icbc.ctp.core.impl.JavaStep.execute(JavaStep.java:103)
        at com.icbc.ctp.core.impl.OperationStep.doExecute(OperationStep.java:101)
        at com.icbc.ctp.core.impl.OperationStep.doExecute(OperationStep.java:87)
        at com.icbc.ctp.core.impl.ExecutableComponent.executeOperation(ExecutableComponent.java:111)
        at com.icbc.ctp.core.impl.ExecutableComponent.executeOperation(ExecutableComponent.java:93)
        at com.icbc.ctp.core.impl.Operation.doInternalExecute(Operation.java:241)
        at com.icbc.ctp.core.impl.Operation.doInternalExecute(Operation.java:278)
        at com.icbc.ctp.core.impl.messagehandler.OpInRequestMsgHandler.handleMessageInternal(OpInRequestMsgHandler.java:100)
        at com.icbc.ctp.framework.seda.handler.AbstractMessageHandler.handleMessage(AbstractMessageHandler.java:65)
        at com.icbc.ctp.framework.seda.dispatcher.UnicastingDispatcher.doDispatch(UnicastingDispatcher.java:105)
        at com.icbc.ctp.framework.seda.dispatcher.UnicastingDispatcher.access$000(UnicastingDispatcher.java:48)
        at com.icbc.ctp.framework.seda.dispatcher.UnicastingDispatcher$1.run(UnicastingDispatcher.java:87)
        at com.icbc.ctp.infra.threadpool.jdk.JDKThreadPoolExecutor$Worker.runTask(JDKThreadPoolExecutor.java:906)
        at com.icbc.ctp.infra.threadpool.jdk.JDKThreadPoolExecutor$Worker.run(JDKThreadPoolExecutor.java:928)
        at java.lang.Thread.run(Thread.java:736)
Caused by: microsoft.exchange.webservices.data.core.exception.service.remote.ServiceRequestException: The request failed. Connection reset
        at microsoft.exchange.webservices.data.core.request.ServiceRequestBase.getEwsHttpWebResponse(ServiceRequestBase.java:729)
        at microsoft.exchange.webservices.data.core.request.ServiceRequestBase.validateAndEmitRequest(ServiceRequestBase.java:639)
        at microsoft.exchange.webservices.data.core.request.SimpleServiceRequestBase.internalExecute(SimpleServiceRequestBase.java:62)
        ... 23 more
Caused by: java.net.SocketException: Connection reset

Any possible solution to this?

P.S : If i use the Basich auth, all is working fine .. but i don't want to prompt the user for his credentials

P.S 2: sorry for my english :D

Thanks in advance!

Viewing all 7132 articles
Browse latest View live




Latest Images