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

  • Home
  • SEARCH
  • 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 8410363
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T00:09:13+00:00 2026-06-10T00:09:13+00:00

In mvc3 application when I create new product, I want to add it’s create

  • 0

In mvc3 application when I create new product, I want to add it’s create date.

 [HttpPost]
 public ActionResult Create( Product product )
 product.CreateDate = DateTime.Now.ToLongDateString();
 ...
  return View( product );
 }

When I will deploy site to hosting, will DateTime.Now create any problem? Does it depend on user’s computers time? If user’s computer time is not correct, product’s create date will be incorrect..I need help about this, always to get real time. Or, advise other way, please. Sorry for my bad english..

  • 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-06-10T00:09:14+00:00Added an answer on June 10, 2026 at 12:09 am

    DateTime.Now will reflect the date and time on the computer that the code is running on (so, in a web application, the server time).

    I suggest using DateTime.UtcNow instead – this will give you a consistent result wherever the computer is (assuming the computer is correctly setup).

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

Sidebar

Related Questions

When I create a new MVC3 application, add a model, add a [Required] attribute
For an MVC3 application I want to create a reusable DAL that is accessed
I'm working on a ASP.NET MVC3 web application and I want to create a
Whenever I create a new Empty MVC3 Web Application project in Visual Studio 2010
I create a simple MVC3 application and then I add in the following route
i have a problem with my mvc3 application, i need to create some Validation
I have created a sample MVC3 application for BookShop. I have a create action.
I've created a new site using mvc3 and now I'm getting closer to the
I am fairly new to unit testing. I am building an ASP.NET MVC3 application
I am creating application in MVC3. I have a ConferenceController which has a Create()

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.