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 869143
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T10:15:42+00:00 2026-05-15T10:15:42+00:00

My C# application send a formatted date (ex: 9/6/2010 – dd/mm/yyyy) to an excel

  • 0

My C# application send a formatted date (ex: 9/6/2010 – dd/mm/yyyy) to an excel spreadsheet… but then… it comes to 6/9/2010! (mm/dd/yyyy)

I just use the following code to send the date:

VarRowColumnWhatever = _MyList.MyObject.MyDateTime.Date.ToString();

Debbuging it, i can see that the value are correct! But not in the spreadsheet =(

I began to think that is something to do with Excel…

Someone please can help me? Thanks!

  • 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-15T10:15:43+00:00Added an answer on May 15, 2026 at 10:15 am

    Stick a string according to the pattern you want into the ToString() portion.

    For instance, to get the Full Day, Month, Date, Year, i’d put:

    _MyList.MyObject.MyDateTime.TimeOfDay.ToString(“D”);

    which would output the string: “Wednesday, June 23, 2010”

    // This example displays the following output to the console:
    // d: 6/15/2008
    // D: Sunday, June 15, 2008
    // f: Sunday, June 15, 2008 9:15 PM
    // F: Sunday, June 15, 2008 9:15:07 PM
    // g: 6/15/2008 9:15 PM
    // G: 6/15/2008 9:15:07 PM
    // m: June 15
    // o: 2008-06-15T21:15:07.0000000
    // R: Sun, 15 Jun 2008 21:15:07 GMT
    // s: 2008-06-15T21:15:07
    // t: 9:15 PM
    // T: 9:15:07 PM
    // u: 2008-06-15 21:15:07Z
    // U: Monday, June 16, 2008 4:15:07 AM
    // y: June, 2008
    //
    // ‘h:mm:ss.ff t’: 9:15:07.00 P
    // ‘d MMM yyyy’: 15 Jun 2008
    // ‘HH:mm:ss.f’: 21:15:07.0
    // ‘dd MMM HH:mm:ss’: 15 Jun 21:15:07
    // ‘\Mon\t\h: M’: Month: 6
    // ‘HH:mm:ss.ffffzzz’: 21:15:07.0000-07:00

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I can send any windows application key strokes with PostMessage api. But I can't
I have written some code in my VB.NET application to send an HTML e-mail
I'd like to encourage our users of our RCP application to send the problem
I've been given a requirement for an internal web application to send documents to
I have an application that needs to send a moderately high volume of messages
I am writing an application that needs to send data over a network. I
we have an application that needs to send out various different types of template
I want to send email from a Ruby application. Is there a call in
I need to send MMS thought a C# application. I have already found 2
Is it possible to send an email from my Java application using a GMail

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.