Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7005125
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T21:18:44+00:00 2026-05-27T21:18:44+00:00

I am programming in Delphi and consuming an API that returns an XSDateTime representing

  • 0

I am programming in Delphi and consuming an API that returns an XSDateTime representing an appointment timeslot. When I try to create a local datatime the time is being converted to my EST timezone (Z-05:00 or Z-04:00 depending on DST). I need the time to remain in the original timezone of CST (Z-06:00). I am currently formatting the time as follows:

aApptListing := FormatDateTime('yyyy/mm/dd t', aSlots[i].StartDateTime.AsDateTime);

where StartDateTime comes in as the time in CST (Z-06:00). How can I keep the original time for CST? For instance, if the date/time comes thru the API as ‘2011-12-25T08:00:00-06:00’ I want to show 12/25/2011 @ 8:00 AM, not 9:00 AM which would be EST.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T21:18:45+00:00Added an answer on May 27, 2026 at 9:18 pm

    It looks like the following should work:

    with aSlots[i].StartDateTime do
      aApptListing := FormatDateTime('yyyy/mm/dd t', EncodeDateTime(Year, Month, Day, Hour, Minute, Second, 0));
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have been programming with Delphi for a long time, and I focused on
I've created a program in Delphi that uses Google's AJAX Search API to evaluate
I have a program written in the Delphi Programming Language that I have to
I've been programming in Delphi with Midas/DataSnap for quite long time and quite happy
I have a couple of newbie Delphi Programming questions that I cannot seem to
I'm wondering how the few Delphi Programming users here are doing unit testing, if
Programming languages had several (r)evolutionary steps in their history. Some people argue that model-driven
Programming is (so far) just a hobby for me, so I try to find
I am trying to learn inline assembly programming in Delphi, and to this end
I need to write a program in any programming language (preferably Delphi 7 /

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.