Search found 79 matches

by Ocalabob
16 Jul 2013 12:20
Forum: DOS Batch Forum
Topic: Command 'grep' and 'awk'
Replies: 3
Views: 5920

Re: Command 'grep' and 'awk'

pinto15,
There are replies to your question on the other forum where you posted.
by Ocalabob
14 Jul 2013 18:57
Forum: DOS Batch Forum
Topic: System Date -90 Days and -180 Days
Replies: 21
Views: 30103

Re: System Date -90 Days and -180 Days

@aGerman, the quotations solve the date problem for me. Thank you!
@foxidrive, those are welcome modifications. I test the script and it works great. Thank you!

Comment:
Now all we need is a question to go with these solutions! :)
by Ocalabob
13 Jul 2013 21:14
Forum: DOS Batch Forum
Topic: System Date -90 Days and -180 Days
Replies: 21
Views: 30103

Re: System Date -90 Days and -180 Days

@foxidrive I did additional editing of your script for testing and I also wanted to leave some 'bread crumbs' for my future editing. Good work. Thank you! Results: C:\!DOSTIPS>date_math.bat Todays date is 07132013 Todays date with seperator is 07_13_2013 90 days ago the date was "04-14-2013&quo...
by Ocalabob
13 Jul 2013 20:33
Forum: DOS Batch Forum
Topic: System Date -90 Days and -180 Days
Replies: 21
Views: 30103

Re: System Date -90 Days and -180 Days

@penpen
Your script gives the date in the correct format which I could probably use with aGermans script.
Screenshot

Code: Select all

SET_DATE_FORMAT = "MM-DD-YY"
DATE_FORMAT     = "DDDD MM/DD/YYYY"
07/13/2013
Press any key to continue . . .


Thank you!
by Ocalabob
13 Jul 2013 20:21
Forum: DOS Batch Forum
Topic: System Date -90 Days and -180 Days
Replies: 21
Views: 30103

Re: System Date -90 Days and -180 Days

@aGerman I hard coded the date in your script changing call :DateToJDN %date% jdn= to call :DateToJDN 07/13/2013 jdn= Screenshot C:\!DOSTIPS>aGerman2.bat Today minus 90 days: 20130414, minus 180 days: 20130114 Press any key to continue . . . The math is working I'll figure out the %date% part later....
by Ocalabob
13 Jul 2013 14:50
Forum: DOS Batch Forum
Topic: System Date -90 Days and -180 Days
Replies: 21
Views: 30103

Re: System Date -90 Days and -180 Days

@aGerman For clarification, when I was testing Antonio's script I was looking for results in the format of: Today minus 90 days: 04-14-2013, minus 180 days: 01-14-2013 Instead, my results were: Today minus 90 days: -47130826, minus 180 days: -47130528 Thanks for your post. I'm off to go test it now....
by Ocalabob
13 Jul 2013 11:49
Forum: DOS Batch Forum
Topic: System Date -90 Days and -180 Days
Replies: 21
Views: 30103

Re: System Date -90 Days and -180 Days

Antonio,
I made the adjustment and that solved the error problem. Thank you.
I still have a date format problem.

Screenshot

Code: Select all

C:\>date_it.bat
Today minus 90 days: -47130826, minus 180 days: -47130528
C:\>
by Ocalabob
12 Jul 2013 19:17
Forum: DOS Batch Forum
Topic: System Date -90 Days and -180 Days
Replies: 21
Views: 30103

Re: System Date -90 Days and -180 Days

@Antonio I am testing your script this evening and ran into a problem. Below are my results: (2nd) C:\>echo %date% Fri 07/12/2013 C:\>date_it.bat Invalid number. Numeric constants are either decimal (17), hexadecimal (0x11), or octal (021). Today minus 90 days: -47130826, minus 180 days: -47130528 C...
by Ocalabob
10 Jul 2013 19:25
Forum: DOS Batch Forum
Topic: System Date -90 Days and -180 Days
Replies: 21
Views: 30103

Re: System Date & system Date - Days Batch Script needed

@foxidrive I tested your scripts; modified the echo lines for my use. Results are below. C:\>main_one "Your program is running" %day% is set to "20130710" (without the quotes) Press any key to continue . . . %day% is set to "20130411" (without the quotes) Press any key ...
by Ocalabob
22 Jun 2013 18:25
Forum: DOS Batch Forum
Topic: batch variable progress bar string manipulation
Replies: 4
Views: 6120

Re: batch variable progress bar string manipulation

@OP,
Some advice. Your calling Endoro a name ("copy cat") on another forum may curtail further help on your failed
attempt at a batch script on this forum. I suggest you refrain from such snarky comments when asking for help.

Your welcome!
by Ocalabob
14 Jun 2013 20:21
Forum: DOS Batch Forum
Topic: how to display password in asterisk
Replies: 15
Views: 42377

Re: how to display password in asterisk

Greetings xhai, I have this script written by Carlos that I like. There is no encryption but it does mask the input. Have fun! ::!CARLOS_HIDE_INPUT.BAT ::Code by Carlos on AMBNT 2013-03-10 ::Subject: Getkey without Display the input. ::Thread started by jeb ::Note: My edits/additions are not indente...
by Ocalabob
05 Jun 2013 12:44
Forum: DOS Batch Forum
Topic: Help with a Xcopy Batch File
Replies: 15
Views: 17362

Re: Help with a Xcopy Batch File

foxidrive wrote:I also get errors and it would seem to be a Robocopy bug on these folders, which are LNKs in the source folder.

Just ignore it.

foxidrive,
Did you try using the /XJ switch?

/XJ :: eXclude Junction points. (normally included by default).
by Ocalabob
04 Jun 2013 18:49
Forum: DOS Batch Forum
Topic: Changing date format of text file column
Replies: 3
Views: 4658

Re: Changing date format of text file column

@Aacini Don't you liked Endoro's answer at: <snip> Good catch Aacini. Looks to me like Endoro is hard at work compiling a solution for the OP on that forum. It would be a shame for someone in this forum to spend a lot of time and effort to duplicate Endoro's work. Endoro is quite capable of problem ...
by Ocalabob
04 Jun 2013 05:37
Forum: DOS Batch Forum
Topic: Batch File to read excel
Replies: 15
Views: 68926

Re: Batch File to read excel

@Carlsomo I tested your script with the batch file below: ::GET_GRADE_50.BAT @Echo off Setlocal Call XLS2CSV.bat my_grades.xlsx For /f "Skip=11 Tokens=3 Delims=," %%b in (my_grades.csv) do set grade=%%b & Goto :score :score If %grade% GEQ 50 Echo "The student passed" & Go...
by Ocalabob
04 Jun 2013 05:25
Forum: DOS Batch Forum
Topic: Batch File to read excel
Replies: 15
Views: 68926

Re: Batch File to read excel

@Aacini, In trying your code I encountered an error. Here's a screen shot: C:\csv_test>xlstocsv input.xls output.csv C:\csv_test\xlstocsv.bat(1, 6) Microsoft JScript compilation error: Conditional compilation is turned off The system cannot find the file output.csv. C:\csv_test> Any ideas to help me...