topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • Saturday September 19, 2026, 4:55 am
  • Proudly celebrating 15+ years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Recent Posts

Pages: prev1 ... 52 53 54 55 56 [57] 58 59 60 61 62 ... 73next
1401
LaunchBar Commander / Re: In Search of A Shutdown/Reboot/Hibernate App
« Last post by Target on June 24, 2009, 05:40 PM »
no credit due here, it's pretty much straight out of the AHK help file...

worth noting that windows (XP at least) already includes a command line to that handles shutting down (but not standby/hibernate - search HELP for shutdown). 

back when i wanted this functionality all the research seemd to indicate that the MS tool was a bit flakey, so I ended up using Andrej Budja's shutdown.exe (this app doesn't do standby or hibernate either).  The homepage for this app appears to be gone, but google turns up plenty of ref's to both the man and the app (posted here for convenience)   
1402
LaunchBar Commander / Re: In Search of A Shutdown/Reboot/Hibernate App
« Last post by Target on June 23, 2009, 10:38 PM »
don't know how this fits with Launchbar Commander, but you could try this little AHK script


#singleinstance
;install, close.ico,close.ico

menu, tray, nostandard

menu, actions, add, LogOff
menu, actions, add, ShutDown
menu, actions, add, Restart
menu, actions, add, Hibernate
menu, actions, add, Suspend
Menu, actions,  show
return

Escape::exitapp

LogOff:
shutdown, 0
return

Shutdown:
shutdown, 9
return

restart:
shutdown, 2
return

Suspend:
DllCall("PowrProf\SetSuspendState", "int", 0, "int", 1, "int", 0)
return

Hibernate:
DllCall("PowrProf\SetSuspendState", "int", 1, "int", 0, "int", 0)
return

running the script generates a popup menu - select the option and you're done. 

If you've run the script in error, escape exits the app

tested OK on an XP SP2 (?) workstation

oh yeah, you need AHK to run the script (but not the exe)
1403
You two are having a go again?

are you following us?
1404
uh oh...
1405
well, you were right about the 'uh oh' bit...
1406
Watch for the next episode of this serial. Lowry eat your heart out
-cranioscopical (June 22, 2009, 06:59 PM)

this conversation is clearly peripheral to the thread!!
1407
so much hub-bub over nothing...

those last ones looks suspiciously like transformers (are the stick people being assimilated?)
1408
try this and let me know how it goes

/*
A DonationCoder coding snack by Target
EpiFile - a TV show filer
dated  - Jun09

moves TV episode files to an appropriately named sub directory

requires a comma separated 'input file' containing the source and base target directories in the format
 'source dir,target dir' or 'd:\temp,d:\temp' (don't include the quotes).  Multiple sources can be
included by adding extra lines eg

d:\temp,d:\temp
d:\temp1,d:\temp
d:\temp2,d:\temp2

questions or feedback should be posted in the forum at -
     https://www.donationcoder.com/forum/index.php?topic=18729.0
*/
#singleinstance
install, epifile.txt, epifile.txt

ifnotexist, epifile.txt
msgbox, INI not found - script will exit
   
Loop, read,epifile.txt
{
    stringsplit, MyPath, A_loopreadline,`,
    loop, %Mypath1%\*.*,0,0
    {
        if a_loopfilename contains .tp ;,000
        {
        }   
        else
        {
            newfold:= regexreplace(a_loopfilename,"-\d\d\d\d\-\d\d-\d\d-.*")
            newfold:= regexreplace(newfold,"- \(.*\)")
            newfold:= regexreplace(newfold," $")
           
            filecreatedir, %Mypath2%\%newfold%
            errorlevel:=0
               
            filemove, %a_loopfilefullpath%, %Mypath2%\%newfold%
            if errorlevel
            {
                if errlist
                    errlist.= "," . a_loopfilefullpath
                else
                    errlist:= a_loopfilefullpath
            }       
            errorlevel:=0
        }
    }
}
fileappend, %mypath1%, %A_YYYY%%a_mm%%A_dd%.error

script will move anything that doesn't contain .TP (this is configurable)

I haven't done anything about locked/in use files - logically this seems more to me an issue of timing.  

Personally I would probably run something like this before the conversion stage.  This would clear out the converted files, and avoid the in use issue completely
1409
USB stick people??
1410
Living Room / Re: What annoys you to no end?
« Last post by Target on June 22, 2009, 12:59 AM »
web pages that don't print, ie you get nothing at all, or maybe the top most frame - GAAAAAGH!!
1411
so we're only moving files that don't contain 'TP'?
1412
cool, many thanks

this might sound like a stupid question, but what i know about video isn't worth repeating, so just to confirm there could be files associated with the converted AVI's, eg XXX.AVI.XXX, XXX.AVI.YYY, etc 
1413
I'm still looking at this but I need a bit more info on what it is you're trying to do

From what you've said so far it sounds like you're -

  • downloading TV shows (as a set of files)
  • Converting each set of files to a corresponding AVI file
  • Moving the final (AVI) file to an appropriately named subfolder
  • deleting the original sets of files (?)

the last step (above) is an assumption on my part.

is this a fair précis of what you're doing?

1414
is there any way to just take the name till you get to the first "-" and ignore the rest?  Would seem to be easier to do that.

Keep in mind that that logic won't work for one of your examples:  A-Team

Ouch...your absolutely right.

I got that, but - ( is perfectly acceptable
1415
looks like there are a number of issues here...

does the conversion process affect all the files, and are all the files required after the conversion?

if you're converting to avi, I suspect you will only need/want the avi files moved (and the balance deleted?)
1416
I can deal with the naming convention, though i'll have to think about the 'in use' problem a bit more
1417
DeVeDe is a nice program (I reviewed it in the mini-reviews section sometime ago) - it's dead simple to use, and you get a nice result at the other end. 

i did quite a bit of further testing and in my case the final video quality didn't end up being very good so I reverted to DVD flick (good quality, but no menus >:().

This could have been because of the source files I was using (I had more than the program could handle, so I had to kludge them together), or because the app (apparently) converts the source into a common format before encoding (too many conversions), or simply because i didn't know what I was doing... 

This isn't to say that DeVeDe isn't a good tool (it is), or that it won't work for you (only one way to find out  :P), only that ultimately it fell short for me
1418
Instead of creating a folder of the show name and copying all episodes to that folder it's creating a folder with BOTH the show name and the episode name...

the problem here is that the naming convention is inconsistent which makes it almost impossible to work out what the correct title is

Where a title includes the episode title will it always be in brackets, and in the format you described (ie NAME - (EPISODE) - XXXX)?

1419

That's easy, have a look at any PC running Windows - OE, (and probably Outlook), and Thunderbird, (IIRC, it's been awhile since I last installed let alone configured it), both default to HTML email and replying to email in the format it was sent.

I don't know about any other email clients but since you're talking about probably the most used one, (OE), it comes back to being "people don't know any better."

They see the pretty emails they can send but they don't see all the junk that's sent to do it, neither are they aware of the risk involved in receiving the damn things.

There's some truth in what you say, but it doesn't answer the question - why does the format persist?

Given that HTML mail is such a well known vector for security breaches it's kind of hard to understand why nobody is making an effort promote a better alternative (rich text?).  Outlook (not express) already includes RTF mail, but it's not as 'mainstream' as others, and it's pointless if the people your sending to can't (or don't/won't) use that format   

The reason that people 'don't know any better' is because they're not being offered an alternative.  And if an alternative exists, it's obvious advantages are not beng promoted

Or could it be that it's in the best interests of the (AV) industry to perpetuate this format?
1420
it's old but still valid - there is no reason to send HTML in an email.

is anyone aware of a reason why HTML mail persists?

wouldn't some sort of rich text format be a far better alternative?
1421
I have no experience with the command line options - I've never needed it so I've never had to learn (but I'll be looking into it now!)

the code you posted probably was close, it just didn't look quite right to me...

There really isn't need for source/target since the new folders should always be created under the original dir

that was my original assumption - but who knows what other people do (or why!)
1422
not sure about the command line part (though I'm pretty sure your posted code isn't correct)

how about this then

#singleinstance

ifnotexist, showme.txt
msgbox, input file not found - script will exit

Loop, read,ShowMe.txt
{
    stringsplit, MyPath, A_loopreadline,`,
    loop, %Mypath1%\*.*,0,0
    {
        RegExMatch(a_loopfilename, "P)^(.*)-\d\d\d\d",TmpVar)
        if TmpVar
        {
            NewFold:= substr(a_loopfilename,1,tmpvar-5)
            filecreatedir, %Mypath2%\%newfold%
            errorlevel:=0

            filemove, %a_loopfilefullpath%, %Mypath2%\%newfold%
            if errorlevel
                fileappend, %a_loopfilefullpath%, ErrorLog_%A_YYYY%%a_mm%%A_dd%

            errorlevel:=0
            tmpvar:=0
        }
    }
}

replaces the INI file with a text file (ie ShowMe.txt) listing the matching source and target folders in the format

source folder 1,target folder 1
source folder 2,target folder 2
source folder 3,target folder 3
source folder 4,target folder 4
source folder 5,target folder 5

Script will loop through the matching pairs - same process, but it will handle multiple directories from a single calling.  any missed files will be logged to a file called ErrorLog_YYYYMMDD (a plain text file)

note that the text file needs to be in the same folder as the script/exe, and as before, if it's not found it will exit



1423
sorry, AHK is required to run the script, but the script can be compiled into a stand alone (attached) if you like

if you use the installer the script can go anywhere as the installation process sets up the associations

Hadn't considered multiple sources and/or targets - how many do you have?
1424
here's a simple AHK script that does what you're looking for


#singleinstance

ifnotexist, showme.ini
msgbox, INI not found - script will exit

iniread, SPath, ShowMe.ini, Paths, source
iniread, TPath, ShowMe.ini, Paths, target

loop, %spath%\*.*,0,0
{
    RegExMatch(a_loopfilename, "P)^(.*)-\d\d\d\d",TmpVar)
    if TmpVar
    {
        NewFold:= substr(a_loopfilename,1,tmpvar-5)
        filecreatedir, %tpath%\%newfold%
        filemove, %a_loopfilefullpath%, %tpath%\%newfold%
        tmpvar:=0
    }
}

it doesn't accept command line parameters (I just knocked this up in my lunch hour) so source and output directories are in an ini file in the format

[PATHS]
Source = d:\temp
Target = d:\temp

if the ini file doesn't exist the script will exit

(All credit to Mouser for the RegEx tip, else I wouldn't have worked this out  :-[)
1425
this may not be quite what you're looking for but it might go someway towards what you seem to be asking for - Barnacle
Pages: prev1 ... 52 53 54 55 56 [57] 58 59 60 61 62 ... 73next