Musings, Ramblings and Other Assorted Rubbish

Just about anything that I can think of... 
Filed under

howto

 

Network Printer Install to All Users

I had a script a few years ago that would lee me install network printers to all users of the computer at one time.  I lost it recently and had to find it again so I am posting it here so I know exactly where to go next time I loose it. 

Just put the unnumbered lines in a .bat file, change to suit your network and run.  

1) This installs printer quietly

rundll32 printui.dll,PrintUIEntry /in /q /n\\servername\printername

2) This deletes the networked printer from the machine being logged onto, and does so quietly. 
rundll32 printui.dll,PrintUIEntry /dn /q /n\\servename\printername

3) This Sets the default printer 
rundll32 printui.dll,PrintUIEntry /y /n\\servername\printername

Filed under  //   How To  

Comments [0]

Google Voice

I received an invite to Google Voice last week and am trying it out.  First impression is complete "Geeky Bliss"! I love the available features and am excited to see more as time goes by. However, the one missing element that surprised me was the lack of the ability to use Google Voice as a soft-phone.  Sure you can originate calls from the web interface then direct the call to a phone of your choosing but not talk there.
To some this may not be a problem, but for me, I have to use my cell phone as a modem when I am out of the house or office so I can not talk on the phone and be on the internet at the same time.  After digging around the help section a while I found a user that was able to get around this little problem. From @Zanthexter: 

Step 1 Set up a GIzmo5 account. 
Step 2 Add the "Gizmo5" phone number to Google Voice. Same as any other phone, just be sure to select the Gizmo TYPE 
Step 3 Configure a SIP compatible soft phone, WiFi phone, Hardline Phone, or SoftPhoneForMobile to answer calls received on your Gizmo5 number.

That's it.. You have to start the call from the Google Voice interface and send it to your Gizmo Phone number that you added and you are set. 


Respectfully,
twitter @dkirkland
Google Voice 979.209.0322

Filed under  //   HowTo  

Comments [0]

Dave Ramsey's Town Hall For Hope

Last month I help our church prepare for the Town Hall For Hope by Dave Ramesy.  Here is the event on line... enjoy!


Dave Ramsey - Town Hall for Hope 2009 from Central FPU on Vimeo.

Filed under  //   How To  

Comments [0]

Old Ultimate Bootdisk 4 Windows?

I keep about 10 of theses in my office to help with every thing form virus/spyware removal to re-imaging full labs and I have recently ran into a problem with Avira's AntiVir program not updating correctly.  It seems this program, although free, requires a license file (hbedv.key) to update the virus def. file.

  Here is a link to the updated .key file
http://dlce.antivir.com/down/windows/hbedv.key

Next I had a problem with downloading the update multiple times in the same room (this thing is several Megs). To fix this, I found the update link to get the file it downloads:

http://dl1.avgate.net/down/vdf/ivdf_fusebundle_nt_en.zip

Finally, I started having problem with Antivir grumbling that the virus def file was corrupt and found that the defs were for a newer version of the program. Here is another work around:

  • Prep Work:
  • Download the current version of Antivr to a clean computer. 
  • Use 7zip to extract the .exe file to a folder 
  • Rename the basic folder to antir (optional) and copy to a USB drive or a network drive
  • Download the update file above
  • Boot up a computer with UBD4wWin disk and use the Antivir on the USB drive.


BTW here is the update to the Adaware program on the Disk:
http://download.lavasoft.com/public/defs.zip

This stuff works in a pinch, but I would advise you to update you UBD4Win iso soon.
And for those that are scratching your heads asking what I am talking about, go here:
http://www.ubcd4win.com/

 

 

Filed under  //   computers   How To  

Comments [0]

No Taskbar, Desktop Icons... Nothing.

Haven't seen this problem before...
A computer had a few viruses and some spyware, but when I removed them the computer starts up and can not start explorer.exe.  I could get to a blank desktop, but there was not a start menu or desktop icons. I had to do CTRL-ALT-DELTET to get to the task manager and run anything.  I was able to get to every thing I needed except explorer.exe which would give me an error about not being able to find it - DANG. 


I ran all the fixes I could find an still was not able to get it to work. in desperation I tried the following and both worked but I would suggest the second method:
Method 1:
First, go to c:\windows and rename explorer.exe to zexplorer.exe and try to launch it. If you get your desktop back, then go to regedit and change 
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon  to zexplorer.exe
This would work but I was not comfortable in having to change the file names to get it to work.

Method 2:
Open regedit and delete HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\explorer.exe then restart the computer.
 Explorer.exe should start up when your computer comes back up.  
Of course before doing either of these, you need to make sure that you have removed all viruses and spyware from your computer.
Good luck!

twitter @dkirkland

Filed under  //   computers   How To  

Comments [0]

I am an Idiot

 OK, so I spent a couple hours fiddling with a project that should have taken a few minutes.  The kid got a PSP for for Christmas and wanted to put some music on it.  No problem... Export her iTunes Playlist and use a script to copy the files...hmmm if was only that easy.  I have a batch file that will read a txt file and use it as an input for something else that works great, but I did not realize that the (whatever.txt) line had to be different for xcopy. Also, the txt file contained "fullpath\2\whatever.ext" one on each line and in quotes.  Here is what I finially had to do to get it to work:

FOR /f "tokens=*" %%X IN ('type fullpath\2\whaterver.txt') DO (XCOPY %%X dest\ /y)
The TYPE statement is manditory! It will not work with out it.
Have fun!
-
Respectfully,
twitter @dkirkland

Filed under  //   How To   Rant  

Comments [0]

Replacing Notepad.exe with Notepad2.exe

I do not like notepad.exe... It will not behave the way I think it should so I replaced it with something better: Notepad2.exe
Hare are some of the features:

  - Syntax highlighting: HTML, XML, PHP, ASP (JS, VBS), CSS,
JavaScript, VBScript, C/C++, C#, Resource Script, Makefiles, Java,
Visual Basic, Pascal, Assembly, SQL, Perl, Python, Configuration
Files, Apache Config Files, Batch Files, Diff Files
- Drag & drop text editing inside and outside Notepad2
- Basic regular expression search and replace
- Useful word, line and block editing shortcuts
- Rectangular selection (Alt+Mouse)
- Brace matching, auto indent, long line marker, zoom functions
- Support for Unicode, UTF-8, Unix and Mac text files
- Open shell links
- Mostly adjustable
Below is a batch file I found to help speed things up (Wish I could remember where I found it to give credit) in replacing notepad.  You will notice that notepad2 has been renamed and is in the folder c:\notepad.  Also you will need to un-hide all system files. 
To install just copy the batch file below into a txt file and name it whatever.bat and run it.  That's it. Have fun.

@echo off
echo ****You must have Notepad2.exe in c:\notepad and named notepad.exe****
pause
copy /y %WinDir%\System32\dllcache\notepad.exe %WinDir%\System32\dllcache\notepad.exe.orig
copy /y %WinDir%\ServicePackFiles\i386\notepad.exe %WinDir%\ServicePackFiles\i386\notepad.exe.orig
copy /y %WinDir%\System32\notepad.exe %WinDir%\System32\notepad.exe.orig
copy /y %WinDir%\notepad.exe %WinDir%\notepad.exe.orig
copy /y C:\notepad\notepad.exe %WinDir%\System32\dllcache
copy /y C:\notepad\notepad.exe %WinDir%\ServicePackFiles\i386
copy /y C:\notepad\notepad.exe %WinDir%\System32
copy /y C:\notepad\notepad.exe %WinDir%
echo.
echo.
echo Write down the locations after the REG_MULTI_SZ or REG_SZ in case the batch file does not work.  If it does not work, you will need to look in the locations from below to find other copies of notepad.exe that are possibly being used to restore the original notepad.exe
echo.
reg query HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup /v "Installation Sources"
reg query HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup /v ServicePackSourcePath
reg query HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup /v SourcePath

twitter @dkirkland

Filed under  //   How To   Open Source  

Comments [0]

Ok, I have had it with IIS... Time to install Apache!

I was reluctant to install Apache because I always thought that it would be too hard.  Lot's of fiddly things to install, mucking about with a bunch of text files... the list went on and on, but as it turns out, I was wrong.  Just go to http://httpd.apache.org/  grab apache_2.2.10-win32-x86-openssl-0.9.8i.msi (at the time of this writing) and run the msi file.  The only change I made was to install everything and point the installer to something like x:\apache  (x being any drive you choose) for easy webroot access. 

This install will do everything! Unlike the PHP installer Apache will work as soon as the installer is finished.  Now the fiddly part that I was afraid of: Getting PHP and MySQL to play nice with it...
Add these three lines to your httpd.conf:

LoadModule php5_module "x:/php5/php5apache2_2.dll"
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
Do a search for DirectoryIndex and make it look like this: DirectoryIndex index.php index.html
That's it! You are done.

Ohh almost forgot if you have set anything to the Inetpub\wwwroot folder in the php.ini file (like upload_tmp_dir or session.save_path), you will need to change it to reflect your new webroot folder:x:\Apache\htdocs

Filed under  //   How To   MySQL   Open Source   PHP   Websites  

Comments [0]

PHP+MySQL+IIS Install

Here are the steps that I took to get PHP and MySQL on IIS:

Software Needed:

  • IIS: Installed on all Windows Servers and can be added to XP Pro via the Control Panel -> Add/Remove Programs -> Add Windows Components.
  • PHP: Can be downloaded from http://www.php.net/ (Be cure to get the Windows Binaries Zip Package NOT the installer package)
  • MySQL: Can be downloaded from http://www.mysql.com  Choose the Community Server download. Also grab the GUI-Tools Administrator while you are there.
  • IZArc: If you do not have an unzip tool this one is one of the best

 

PHP Install

Unzip the PHP binaries package (php-5.x.x-Win32.zip) to C:\PHP5 and do the following:

  • Copy php.ini-recommended to C:\windows\ and rename to php.ini.
  • Copy php5ts.dll to C:\windows\System32

 

Let IIS know you have PHP

 You have to tell IIS where PHP is and add the extensions:

  • Open IIS control panel and expand the computer name to reveal "Web Sites" right click to properties.
  • Click on the Home Directories tab and look for and click on the Configuration button
  • On the Mappings tab click Add button, browse to C:\php5 and select php5isapi.dll.  Then type .PHP in the extension field (Yes, type the period first)
  • Next go to the Documents tab and add index.php as a new document and move it up to the top of the list.
  • Add C:\PHP5 to your system Path
    • In a cmd windows type PATH C:\PHP5; %PATH%

 

Testing PHP
  • Go to your webroot folder (C:\Insetpub\wwwroot) and copy the following into a newly created text file phpinfo.php:

<?PHP phpinfo(); ?>

  • Open a web browser and point it to http://localhost/phpinfo.php You should see the PHP information page.  It contains all config variables that are loaded from the php.ini file.  If you see this page, PHP is installed and configured.

 

MySQL Install

Unzip the MySQL file that you downloaded earlier and run Setup.exe

  • Choose Compete Install and click NEXT till starts to copy files
  • Choose Configure the MySQL Server now
  • Pick Detailed Configuration
  • Select Server Machine
  • Choose Multifunctional Database
  • Leave the Default settings for InnoDB Tablespace
  • Pick Online Transaction Processing
  • Leave the networking options at the default settings
  • Choose Standard character set
  • Check Install as a service and include in to Path
  • Modify Security settings and choose a new root password
  • Click Execute to begin the configuration process
  • Press Finnish

 

Add a user to test with:

Open the SQL Administrator Command Line and type the next commands (hit enter after each line)

CREATE USER 'test'@'localhost' IDENTIFIED BY 'test';

FLUSH PRIVILEGES;

This will create a user called test with a password of test

 

Bringing It All Together

Now we have to let PHP know that MySQL has been install:

 Open the php.ini file (Start -> Run -> php.ini) and either uncomment or add the following:

 extension=php_mbstring.dll

extension=php_mysql.dll

extension=php_mysqli.dll

 Save the php.ini file and restart IIS

 

 Testing PHP & MySQL Together

 Type the following in a text file and name it test.php

 <?php

// Let's connect and select a database

$link = mysql_connect('localhost', 'test', 'test')

 or die('Couldn't connect to the MySQL Server: ' . mysql_error());

mysql_select_db('mysql') or die('Couldn't Select the Database.<br><br>

The error returned by MySQL says: <br>' . mysql_error());

// See Ya!

mysql_close($link);

?>

 

This page will comeback with the errors:

 Couldn't Select the Database.
The error returned by MySQL says:
Access denied for user 'test'@'localhost' to database 'mysql'

 This was just to see if PHP could see the MySQL Server.  If you see this error it is install and working. 

Filed under  //   How To   MySQL   Open Source   PHP   Websites  

Comments [1]