Jump to content
Slate Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate Marble
Slate Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate Marble

Archived

This topic is now archived and is closed to further replies.

RadioGaGa

Computer Programming....DOS maybe?

Recommended Posts

So, I know jack shit about computer programming outside of some basic HTML. I'm not sure if this is DOS, C++ or what language, but I have a small program that uses

%DATE%

to fill in that days date as a start date on an audio file is loaded into our system...I want to automatically set a stop date of 6 days later using a similar formula...

I know this is vague...but does anyone have a thought on how I can make this work?

Share this post


Link to post
Share on other sites

Whewwwww its been awhile since I had programming anything, but I will at least give some overall programming insight so you can google your way to solving your problem...maybe.

-First thing, we somewhat need to know what language were dealing with here.

-Second, if from what Im gathering, you put something in at a somewhat random time, and assign it %date%. (I am going to assume it saves %date% as something, say like date1). SOOOO, what youre going to need to do, is hopefully see what %date% is defined as, then for your stop date, youre going to do some sort of command where you say something like (here comes the VB in me) [date2=date1 + 6]

if date1 = date2

then stop (or whatever the command is depending on the language).

else (give it some random task to go off and do).

Now, if you have a program from some corporation that has their own template and what not, and %date% assigns that day (think excel here) then you will be highly handcuffed and will just have to see if you can manipluate the %date% command into a formula. I already see a problem in this in that I bet the company only has %date% as a dynamic variable, thus, making it really hard without being able to have the initial date defined.

Hopefully there is some simple command out there for you, and you can ignore everything above.

Zach

Share this post


Link to post
Share on other sites

If you're using windows batch scripting, there really aren't any easy ways to manipulate dates. However, if you're not opposed to using a vbscript, it can be done easily. For instance,

wscript.echo(dateadd("d",date(),1))

displays tomorrow's date.

Microsoft has a great guide for syntax and use of it here: MS Scripting Guide

If you're editing a file with the extension .cmd, it's a windows batch script.

Share this post


Link to post
Share on other sites

Hmmm....Hard to explain what language, cause I don't know. l What I have is a header file (*.asc) that when paired with a WAV file files and dropped onto the network, fills in the fields in the Windows based system we use. It's a shortcut around having to load audio in real time. So, I don't have access to actually re-write any code. Just define the information that gets put into those fields.

%DATE% enters todays date into the "Start" field" but as of now, I have to fill in an actual end date....

I was hoping the commands would be the same as Excel values for Date & Time, but it doesn't look like they are.

Share this post


Link to post
Share on other sites

×
×
  • Create New...