3 Replies - 965 Views - Last Post: 13 June 2011 - 07:46 AM Rate Topic: -----

#1 vbnewbiee  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 1
  • Joined: 12-June 11

Simple question on datetimepicker

Posted 12 June 2011 - 01:24 AM

Hi folks,

I am a new joiner on this forum and have a very simple question - hoping someone can help me.

I want to save datetimepicker value of date and time in two separate text files. Currently, when I select a date from datetimepicker and save it in a text file it saves both date and time as below:

5/11/2011 8:25:06 PM

What I would like to happen is as below:

Datefile.txt saves 5/11/2011
Timefile.txt saves 8:25:06 PM

Alternative solution that can work for me would be, if the time (only the TIME) can be modified after saving as below:

saved datetime into text file is 5/11/2011 8:25:06 PM

How can I modify the time only to say 12:00:00 PM.

By doing so I would like to keep time as 12:00:00 but date can be changed by the user using the datetime picker.

Any ideas? Thanks in advance friends..

Is This A Good Question/Topic? 0
  • +

Replies To: Simple question on datetimepicker

#2 BobRodes  Icon User is offline

  • Your Friendly Local Curmudgeon
  • member icon

Reputation: 574
  • View blog
  • Posts: 2,989
  • Joined: 19-May 09

Re: Simple question on datetimepicker

Posted 12 June 2011 - 10:19 AM

investigate the left and mid functions.
Was This Post Helpful? 0
  • +
  • -

#3 thava  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 180
  • View blog
  • Posts: 1,606
  • Joined: 17-April 07

Re: Simple question on datetimepicker

Posted 13 June 2011 - 03:51 AM

use the format function
Was This Post Helpful? 0
  • +
  • -

#4 BobRodes  Icon User is offline

  • Your Friendly Local Curmudgeon
  • member icon

Reputation: 574
  • View blog
  • Posts: 2,989
  • Joined: 19-May 09

Re: Simple question on datetimepicker

Posted 13 June 2011 - 07:46 AM

Well, that might be a better solution too. :)
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1