Solved

how to get "Teusday" from  "30JUL02"

Posted on 2002-07-30
10
168 Views
Last Modified: 2010-05-01
I want the day of the week from  "30JUL02"
0
Comment
Question by:josmic
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 2
  • 2
  • +1
10 Comments
 
LVL 20

Expert Comment

by:hes
ID: 7188643
Try this:

Dim Temp As String
Dim MyDate As Date
Dim CurDay() As String
Temp = "30JUL02"
MyDate = Left(Temp, 2) & "-" & Mid(Temp, 3, 3) & "-" & Right(Temp, 2)
Temp = FormatDateTime(MyDate, vbLongDate)
CurDay = Split(Temp, ",")
MsgBox CurDay(0)
0
 

Expert Comment

by:joebenz
ID: 7188682
Convert it to 30/07/02 ,then call:

Dim mydate

mydate="30/07/02"
Format(MyDate,"Long Date")
0
 
LVL 5

Accepted Solution

by:
jayeshshah earned 50 total points
ID: 7188715
use the below

WeekdayName(Weekday(Now), True)

here instead of now you can change the date whose day u r needing.

n'joy

Jayesh
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Expert Comment

by:joebenz
ID: 7188728
To jayeshshah:
Remember that the format is "30JUL02".
Cheers.
0
 

Author Comment

by:josmic
ID: 7189265
thanks but sorry input output wrong and and almost working answer b4 yours.
0
 

Author Comment

by:josmic
ID: 7189268
hes 0 was month/day and 1 was year could not make work for day of week.
0
 

Author Comment

by:josmic
ID: 7189269
oops that was u thanks
0
 

Author Comment

by:josmic
ID: 7189270
oops that was u thanks
0
 
LVL 20

Expert Comment

by:hes
ID: 7189439
What ?
You accepted jayeshshah's wrong answer ?
0
 

Author Comment

by:josmic
ID: 7277590
WeekdayName was preffered hes, sorry.
Also your code like mine errs on some diff date setting other then north america.
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question