Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Sending outlook meeting request from SAP

Former Member
0 Kudos

Dear All

I used the below link to send the microsoft outlook meeting request from SAP
https://wiki.scn.sap.com/wiki/display/Snippets/SAP+ABAP+to+Outlook+Calendar+Entry

everything working fine except the time which iam passing not reflecting in outlook.

below are lines of code which i have used for displaying date and time in outlook

CONCATENATE 'DTSTART:' p_begda 'T140000Z' INTO ls_soli-line. APPEND ls_soli TO lt_soli. CONCATENATE 'DTEND:' p_endda 'T220000Z' INTO ls_soli-line.

please help in this regards.

10 REPLIES 10

larshp
Active Contributor

Can you elaborate on "not reflecting in Outlook?"

The "Z" in the time usually means UTC, see https://www.w3schools.com/xml/schema_dtypes_date.asp, so this might explain a different time than 14 showing up in outlook, if this is the problem?

Former Member
0 Kudos

Thanks Lars for quick reply

As per my requirement we need to pass start time for example 11:00 am and end time as 11:30 am

Sandra_Rossi
Active Contributor
0 Kudos

Just to be sure, please tell us what time appears in the Outlook appointment?

Former Member
0 Kudos

Thanks for the reply Sandra.

Now it is displaying 04:00 - 04:30 instead of 12:00 to 12:30.

Sandra_Rossi
Active Contributor
0 Kudos

If 04:00 is 04:00 AM, then your time zone is Pacific Standard Time (PST) = UTC-8.

You need to transmit the UTC time corresponding to 12:00 PST.

The following sample demonstrates how to convert a PST time into UTC (ASSERT is just here to demonstrate the assertion):

DATA date TYPE d VALUE '20171111'. " time given in PST
DATA time TYPE t VALUE '120000'. " time given in PST
DATA timestamp TYPE timestamp.
" 2017/11/11 14:00:00 being expressed in PST, convert it into UTC timestamp
CONVERT DATE date TIME time INTO TIME STAMP timestamp TIME ZONE 'PST   '.
" convert the UTC timestamp into date and time expressed in UTC (blank time zone)
" (i.e. no conversion)
CONVERT TIME STAMP timestamp TIME ZONE '      ' INTO DATE date TIME time.
ASSERT date = '20171111' AND time = '200000'. " time given in UTC

.

Sandra_Rossi
Active Contributor
0 Kudos

If 04:00 is 04:00 PM, then your time is UTC+4:

DATA date TYPE d VALUE '20171111'. " time given in UTC+4
DATA time TYPE t VALUE '120000'. " time given in UTC+4
DATA timestamp TYPE timestamp.
" 2017/11/11 14:00:00 being expressed in UTC+4, convert it into UTC timestamp
CONVERT DATE date TIME time INTO TIME STAMP timestamp TIME ZONE 'UTC+4 '.
" convert the UTC timestamp into date and time expressed in UTC (blank time zone)
" (i.e. no conversion)
CONVERT TIME STAMP timestamp TIME ZONE '      ' INTO DATE date TIME time.
ASSERT date = '20171111' AND time = '080000'.

Former Member
0 Kudos

Thanks Sandra for helpful reply.

now i can able to display the selected time but instead of 11:00 AM its displaying as 11:00 PM

0 Kudos

Thanks Sandra.

its resolved.

Former Member
0 Kudos

Dear Sandra,

how to default the Invite attendees now iam getting as attachment on opening i can save the appointment

but client wants to send as invitation to attendees.

0 Kudos
That's another question, not related to ABAP -> see RFC5545 for ICalendar: chapter 3.2.11 Group or List Membership

https://tools.ietf.org/html/rfc5545#page-20

See an example in the comments of this blog post: https://blogs.sap.com/2009/08/04/how-to-send-appointments-or-meeting-requests-from-sap-systems/