Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Locked thread
Mad Brahmin
Dec 29, 2004

Oranjeboom posted:

Wow, awesome to see this thread return. I have a request for what I take to be a pretty quick wav audio file splitter:

A fast, no-frills app which splits wav files into a desired number of even segments, saving those files to a subdirectory:
-- Input syntax like "wavsplit -9 somesound.wav", which will split somesound into 9 equally sized wav files, and save them to ../pieces/
-- Preferably doesn't need to load the entire wave file into memory, so that large (multi-gb) files can be easily split.

Someone might have done this before, but I've only found spyware, memory-intensive (ie, doesn't load the whole 2gb file into memory first), or overkill software.

Hopefully this works, but I'm sure it will butcher any headers for the split files. It would probably be recommended to backup the source file before testing this out even though it's opened for reading only.

Usage: wavsplit numberOfFiles sourceFile outputPrefix

outputPrefix is optional and will rename the files prefix_####.wav instead of sourceFile_####.wav. Output files will be stored in sourcePath/../pieces/. The last piece will probably be a few bytes larger than the rest.

http://www.tinyappz.com/images/a/ac/WavSplit.zip

Adbot
ADBOT LOVES YOU

Mad Brahmin
Dec 29, 2004

Deserted posted:

My Request:

A small windows app that:
* On the press of a key combination (CTRL+SHIFT+Z+X):
* Clears the Firefox Cache
* Closes Firefox
* Runs C:\Program Files\Webroot\Washer\wwDisp.exe

If closing firefox is hard, it doesn't have to do that, though I do prefer it.

Would the following work for you? I couldn't find a quick way to have a multiple key global hotkey so I made it control+alt+shift+z.

What it does:
* On press of key combination (CTRL+SHIFT+ALT+Z)
* Closes Firefox
* Executes doStuff.bat in the background
* Runs in the background. Exit by ctrl+alt+delete and end process.

With doStuff.bat you can choose exactly what you want to happen after Firefox is closed. "rem 500" at the beginning of doStuff.bat is how long to wait (in milliseconds) before executing the batch file after closing Firefox. This is so Firefox can release its grasp on the cache files so you can delete them.

http://www.tinyappz.com/images/7/7b/FirefoxClose.zip

Mad Brahmin fucked around with this message at 05:41 on Apr 8, 2007

Mad Brahmin
Dec 29, 2004

JediGandalf posted:

I would imagine they have to otherwise the OS can't disable the device when I tell it to in the device manager. Unless device disabling is done some other method.

I don't think I've seen any device management functions in the Windows API. You could probably grab the source to devcon included in the Windows Driver Development Kit and hack it into a nice interface. Devcon is similar to the Windows device manager, but in console form.

http://www.microsoft.com/whdc/devtools/ddk/default.mspx

Mad Brahmin
Dec 29, 2004

Ramzi posted:

Two digits of hex can represent 256 different values. Two digits of hex represents one byte. There are 256 ASCII characters. Each ASCII character is one byte.

If we mapped a unique ASCII char to a unique hex value, then a text file of ASCII characters can contain the information of non-text files, such as images and executables.

Some free webspace services only accept the uploading of certain recognized file types. To circumvent this restriction, could someone code a program that would open a file of any type and convert it to a .txt file of ASCII garble. Then, take in a .txt file of ASCII garble, and convert it back to what it was?

The file extensions are not a concern for a program. After a text file is converted back, I will then change the extension manually.

Just rename the file, but with a .txt extension. Files are stored the same way regardless of name. The name is just a way to reference the actual data.

Mad Brahmin
Dec 29, 2004

Raar_Im_A_Dinosaur posted:

...a program where I fill in fields and come out with ready to copy-paste versions for both forums and website...

http://tinyappz.com/wiki/Silicon_Valley_LP_Thing

Copies text from field to clipboard when specified button is pressed. I think it should work, I never really worked with c# before.

Mad Brahmin
Dec 29, 2004

placebo posted:

I'd like an app that will just press a key combo over and over again until I tell it to stop

These kinds of things can be done very easily in AutoIt. When the following is run then started (control y) it will send asdf until it is stopped by either exiting (control u) or stopping (control t). The program includes a bunch of examples and a decent help file.

code:
$Running = 0

AutoItSetOption("SendKeyDelay", 1)

HotKeySet("^y", "Start")
HotKeySet("^t", "Stop")
HotKeySet("^u", "Terminate")

While 1
	if($Running == 1) Then
		Send("asdf")
		Sleep(500)
	EndIf
WEnd

Func Start()
	$Running  = 1
EndFunc

Func Stop()
	$Running = 0
EndFunc

Func Terminate()
	Exit 0
EndFunc
Remove Sleep(500) or reduce the value to make it send the keys faster. The character right before the hotkey is the optinal modifier: ^ for control, ! for alt, + for shift, # for windows key

Mad Brahmin fucked around with this message at 20:05 on Mar 10, 2008

Mad Brahmin
Dec 29, 2004
The only way I know how to move the taskbar is in XP and it's rather ugly. Set byte 13 of HKCU\Software\Microsoft\windows\CurrentVersion\Explorer\StuckRects2\Settings to a value of 0-3 (ABE_LEFT, ABE_TOP, ABE_RIGHT, ABE_BOTTOM) then kill Explorer. When it comes up again the bar should be in it's new position, but it may be missing a few tray icons. Here's an example of the above in c:

You might want to backup that registry key just in case something messes up and kills your task bar since this was quickly thrown together.

http://www.tinyappz.com/wiki/images/6/63/MoveTaskbar.zip

Mad Brahmin
Dec 29, 2004

Mensur posted:

I shoot photos in raw and jpg simalaniously. The images share the same name before the dot but have different extensions, i.e. when I press the shutter I get IMG_847.JPG and IMG_847.CR2 on my card.

When I put the files on my PC I usually browse through the raws and delete what I don't like. It's not uncommon for this to be several hundred images per day. It would be nice to have a program that could look at the files in the directory and see that if IMG_847.CR2 does not exist that IMG_847.JPG should be deleted.

For future proofing the ability to configure the extensions would be nice. Also displaying a list of files to be deleted with a confirmation box would be handy too if it's not too much trouble.

e: I guess I should specify windows vista / 7

See if you can get this to run. It should be under .Net 3.5. You might want to play around with it for a bit to see if it does what you want it to do.

http://tinyappz.com/wiki/RemoveUnpairedFiles

Mad Brahmin
Dec 29, 2004

NickNails posted:

Using DOS Batch commands (hey, it's the only thing that runs my PnP machines).

Files are created as such:

PCB041A01.ext
PCB041B01.ext
PCB041C01.ext
PCB022A02.ext

Each new file of the same type gets the next incrementing letter. So on and so forth. Now I have a directory full of different revisions of files. I would like to be able to have something automatically go through and move any files that are below an existing files into a subfolder. In the example above: only PCB041A01.ext and PCB041B01.ext would get moved to the subfolder.

http://tinyappz.com/wiki/MoveOldRevisions please backup your files before using, or use on a test batch of files to see if it does what you want.

Moves files named "...XYZ..." (where X and Z are numeric, Y being a-zA-Z) when there exists a file "...XNZ..." where N is greater than Y

Mad Brahmin
Dec 29, 2004

Steakandchips posted:

autoit stuff

This is pretty simple if you're able to run AutoIt. Here's a script that will read a comma separated value file and will type each value followed by a Tab until it gets to the last value on the line, where it will send the Down key instead of Tab. The keys it sends, hotkeys, data file, and delimiter can be changed in the first few lines of the script using notepad.

The default hotkey to start the typing is the Pause/Break key and the key to abort it Escape. View Send.html for details on changing what keys it sends.

http://www.tinyappz.com/wiki/images/b/b0/ReadData.zip


Sample csv file data.txt:
code:
FOO, 123, 456
BAR, 555, aaa, abc
Baz, 1a1, a1a

Mad Brahmin fucked around with this message at 22:23 on Jun 21, 2009

Mad Brahmin
Dec 29, 2004
I just have the default file name as data.txt and it looks in the current directory, which should be where the ReadData.au3 file is. You can also change "data.txt" to an absolute path such as "c:\stuff\data.txt" on the first line if that isn't working.

Mad Brahmin
Dec 29, 2004
First time messing with Greasemonkey so this may not work. Just overwrite the old code with this:

code:
// ==UserScript==
// @name           Imdb Killer
// @namespace      IMDB
// @description    Kills the left hand imdb Toolbar
// @include        [url]http://www.imdb.com/*[/url]
// ==/UserScript==

var sidebarMainPage = document.getElementById('lhs');
var sidebarMoviePage = document.getElementById('tn15lhs');
var mainContent = document.getElementById('tn15main');

if(sidebarMainPage)
{
	sidebarMainPage.parentNode.style.display = "none";
}

if(sidebarMoviePage)
{
	sidebarMoviePage.style.display = "none";
	if(mainContent)
	{
		mainContent.style.marginLeft = 0;
		mainContent.style.border = 0;
	}
}

Adbot
ADBOT LOVES YOU

Mad Brahmin
Dec 29, 2004

Corla Plankun posted:

Is there a way to tell the difference between an animated GIF and a regular one in software? I have a big pile of GIFs I got from a website and I want to sort them into two folders (animated, not animated). I feel like a simple script could do this if there is a key difference in file headers or something like that.

This is pretty easy to do in c# since the Image type from System.Drawing contains a method to get the number of frames in an image. This should move all animated gifs in the same directory as sortgifs.exe or a specified path into ./animated and all static images into ./static.

https://sites.google.com/site/madbrahmin/SortGifs.zip

edit: beaten

  • Locked thread