Computer Learning Zone CLZ Access Excel Word Windows

Don't know if it's good or bad that a Google search on "Big Bang Theory" lists the sitcom before the origin of the Universe

-Neil deGrasse Tyson
 
Home   Courses   Seminars   Templates   TechHelp   Forums   Help   Contact   Join   Order   Logon  
 
Home > TechHelp > Access >
TechHelp


Back to TechHelp
 

DOS alternative Upload Images   Link  
Sandra Truax 
3 months ago
I still use DOS to open folders by year and month as follows (along with other tasks).  What is a better alternative to using the below DOS code?

For /f "tokens=2-4 delims=/ " %%a in ('date /t') do (set mydate=%%c-%%a-%%b)
For /f "tokens=1-2 delims=/:" %%a in ("%TIME%") do (set mytime=%%a%%b)

set year=%date:~10,4%
set month=%date:~4,2%
set day=%date:~7,2%
set filename=%year%_%month%_%day%

start %windir%\explorer.exe "d:\j\%YEAR%\%MONTH%"
Alex Hedley
3 months ago
> What is a better alternative to using the below DOS code?

Why do you need an alternative?

Could use .NET, PowerShell, python, anything'
Sandra Truax
3 months ago

Sandra Truax
3 months ago
Because of Richard's comment on a previous post I made. I attached the conversation.
Scott Axton
3 months ago
Sandra I believe that you can use the DatePart function to build up your variable parts for the Y/M/D.  Then just concatenate them together to replace the
"d:\j\%YEAR%\%MONTH%" part of your

I know you aren't there yet but Richard starts covering the File System Object Starting in Developer 33 and continues on in 34 and 35.  Those may be of use (eventually).  

One thing I would add is, "If it ain't broke, why fix it?".  I don't see an issue with how you are doing it now.
Alex Hedley
3 months ago
Previous post: DOS

This thread is now closed. If you wish to comment, start a NEW discussion, below.
 


Back to TechHelp Comments
 

Start a NEW Conversation
 
Only students may post on this page. Click here for more information on how you can set up an account. If you are a student, please Log On first. Non-students may only post in the Visitor Forum.
 
Subscribe
Subscribe to TechHelp
Get notifications when this page is updated
 
 
 
 

The following is a paid advertisement
Computer Learning Zone is not responsible for any content shown or offers made by these ads.
 

Learn
 
Access - index
Excel - index
Word - index
Windows - index
PowerPoint - index
Photoshop - index
Visual Basic - index
ASP - index
Seminars
More...
Customers
 
Login
My Account
My Courses
Lost Password
Memberships
Student Databases
Change Email
Info
 
Latest News
New Releases
User Forums
Topic Glossary
Tips & Tricks
Search The Site
Code Vault
Collapse Menus
Help
 
Customer Support
Web Site Tour
FAQs
TechHelp
Consulting Services
About
 
Background
Testimonials
Jobs
Affiliate Program
Richard Rost
Free Lessons
Mailing List
Order
 
Video Tutorials
Handbooks
Memberships
Learning Connection
Idiot's Guide to Excel
Volume Discounts
Payment Info
Shipping
Terms of Sale
Contact
 
Contact Info
Support Policy
Mailing Address
Phone Number
Fax Number
Course Survey
Email Richard
[email protected]
Blog RSS Feed    YouTube Channel

LinkedIn
Copyright 2023 by Computer Learning Zone, Amicron, and Richard Rost. All Rights Reserved. Current Time: 9/26/2023 12:23:50 AM.