OberonPlace.com Forums  

Go Back   OberonPlace.com Forums > Developer Forums > VBA > CorelDRAW/Corel DESIGNER VBA

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 27-10-2004, 10:24
ddonnahoe's Avatar
ddonnahoe ddonnahoe is offline
Senior Member
 
Join Date: Jan 2004
Location: Louisville, KY
Posts: 552
Send a message via ICQ to ddonnahoe Send a message via AIM to ddonnahoe Send a message via MSN to ddonnahoe Send a message via Yahoo to ddonnahoe
Default Date Picker Tweak

I am using CD11 and have NeoComponents Date Picker. All works fine with my code and the macro works perfectly. However, I am trying to tweak my code a little so that the resulting document is saved to a specific folder with a certain file name (i.e. c:\orderforms\102704-BlackTShirt.cdr) and then close the document or at least give the option to close.

Where "102704" is todays date and the "BlackTShirt" is the value from another input from the form.

The problem is, no matter what I do with the Date Picker settings to change the format, it still shows up as 10/27/2004. What I want to do is remove the "/" and the leading "20" in the year, then save it as...

"c:\orderforms\" & AmendedDate.Value & "-" & PONumber.Text & ".cdr"

I hope this makes sense. I am enclosing pics of what I'm talking about...
Attached Images
  
__________________
Sean
Waiting for a ride in the T.A.R.D.I.S.
Reply With Quote
  #2  
Old 29-10-2004, 09:33
ddonnahoe's Avatar
ddonnahoe ddonnahoe is offline
Senior Member
 
Join Date: Jan 2004
Location: Louisville, KY
Posts: 552
Send a message via ICQ to ddonnahoe Send a message via AIM to ddonnahoe Send a message via MSN to ddonnahoe Send a message via Yahoo to ddonnahoe
Default

Does anyone have a response for this? Please?
__________________
Sean
Waiting for a ride in the T.A.R.D.I.S.
Reply With Quote
  #3  
Old 29-10-2004, 10:02
Alex's Avatar
Alex Alex is offline
Administrator
 
Join Date: Nov 2002
Posts: 1,940
Blog Entries: 4
Default Re: Date Picker Tweak

You can use VBA's Format function to reformat your date to the format you need. For example:

Code:
MsgBox "Today is " & Date
will show a message box saying "Today is 10/29/2004". However if you use this code:

Code:
MsgBox "Today is " & Format(Date, "mmddyy")
you will get "Today is 102904".

I think that's what you need.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
VB help for date field Kristian CorelDRAW/Corel DESIGNER VBA 4 28-01-2005 04:14
Date? androo CorelDRAW/Corel DESIGNER VBA 2 10-01-2005 15:57
document name and created date in Corel drawing eric CorelDRAW/Corel DESIGNER VBA 5 14-09-2004 22:17
Can I hange month start date on yearly single page calendar kingfish Calendar Wizard 2 22-02-2004 20:56
Calendar Date Selection ddonnahoe CorelDRAW/Corel DESIGNER VBA 3 15-01-2004 10:08


All times are GMT -5. The time now is 03:28.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.
Copyright © 2011, Oberonplace.com