Sunday, February 27, 2011

FIND BIG FILES BY EXCEL FILE

 
' BigFiles Macro
 
' This software is provided as-is, without any warranty, either
' express or implied, including the implied warranties of
' merchantability or fitness for a particular purpose. In no event
' will the author be liable to you for any special, consequential,
' indirect, or similar damages. In no case shall the author's liability
' exceed one dollar.
 
Dim bigfile As Double
Dim base As String
Dim row As Integer
Dim fso
 
Sub BigFiles()
  Dim s As String
 
' specify how big
  s = InputBox( _
          "How big is big?" + vbCrLf + _
          "Your report will show all big files and all big folders." + vbCrLf + _
          "Specify threshhold size in MB", , "10")
  If s = "" Then
    Exit Sub ' user hit cancel
  End If
  bigfile = CDbl(s) * 1048576# ' convert from MB to bytes.
 
' determine beginning path
' if a cell in the name col is selected,
'   we're drilling down.
'   start with selected folder,
'   report on sheet 2
' else
'   starting with root.
'   ask for drive letter
'   report on sheet 1
  Sheets(1).Name = "Drive"
  Sheets(2).Name = "Drill Down"
  If Selection.Column = 10 Then
    base = Selection.Value
    Worksheets("Drill Down").Activate
  Else
    base = InputBox("Enter Drive Letter", , "C")
    If base = "" Then
      Exit Sub ' user hit cancel
    End If
    base = base + ":\"
    Worksheets("Drive").Activate
  End If
 
' Erase entire spreadsheet
  Cells.Select
  Selection.ClearContents
 
  row = 1
  ' create a file system object, to access the file system
  Set fso = CreateObject("Scripting.FileSystemObject")
 
  ' and so it begins
  Cells(1, 1).Select
  grandtotal = GetFolderSize(base, 0) ' start with base folder, level zero
 
  ' Done!
  
  ' Label Headers and format columns
  Range("A1").Select
  ActiveCell.FormulaR1C1 = "Created"
  Range("B1").Select
  ActiveCell.FormulaR1C1 = "Modified"
  Range("C1").Select
  ActiveCell.FormulaR1C1 = "Accessed"
  Range("D1").Select
  ActiveCell.FormulaR1C1 = "Base"
  Range("E1").Select
  ActiveCell.FormulaR1C1 = "Sub 1"
  Range("F1").Select
  ActiveCell.FormulaR1C1 = "Sub 2"
  Range("G1").Select
  ActiveCell.FormulaR1C1 = "Sub 3"
  Range("H1").Select
  ActiveCell.FormulaR1C1 = "Deeper"
  Range("I1").Select
  ActiveCell.FormulaR1C1 = "Size"
  Range("J1").Select
  ActiveCell.FormulaR1C1 = "Name"
  Columns("A:C").Select
  Selection.NumberFormat = "m/d/yy"
  Columns("D:I").Select
  Selection.NumberFormat = "#,##0"
  Range("A2").Select
  ActiveWindow.FreezePanes = True
  If row > 2 Then
    Selection.Sort Key1:=Range("J5"), Order1:=xlAscending, Header:=xlGuess, _
      OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom
  End If
  Columns("A:J").EntireColumn.AutoFit
 
  Cells(1, 1).Select ' shift sheet full left
  Cells(2, 4).Select ' park in base folder size
  MsgBox ("DONE!")
End Sub
 
' *********************************************************8
' Here's where the work gets done
Function GetFolderSize(FolderName, depth)
  Dim totalsize As Double, mbsize As Long, sfsize As Double
  Dim s As String
  Dim lastslash As Integer, col As Integer
  Dim folder
 
  ' progress
  Cells(1, 1) = FolderName
  DoEvents
 
  ' get a folder object to access this folder
  Set folder = fso.GetFolder(FolderName)
 
  ' can't do system protected folders, except root, of course
  ' for example, if you look at "SYSTEM VOLUME INFORMATION",
  ' you get "access denied"
  ' This attempts to see the folder, but doesn't die if denied.
  If Not folder.IsRootFolder Then
    On Error Resume Next ' dont die if next stmt bombs
    totalsize = folder.Size ' err occurs if protected
    If Err <> 0 Then ' if there was an error...
      Err = 0
      GetFolderSize = 0
      Exit Function
    End If
    On Error GoTo 0 ' errors kill again.
  End If
 
  'add in length of each individual file in this folder.
  totalsize = 0
  Set filelist = folder.Files ' get a file list
  For Each file In filelist
    ' progress
    Cells(1, 1) = file.Path
    DoEvents
    totalsize = totalsize + file.Size
    ' ***********************************************************
    If file.Size >= bigfile Then
      row = row + 1
      Cells(row, 1) = file.DateCreated
      Cells(row, 2) = file.DateLastModified
      Cells(row, 3) = file.DateLastAccessed
      Cells(row, 9) = CLng(file.Size / 1048576)  ' MB
      s = file.Path
      lastslash = InStrRev(s, "\")
      If lastslash > 3 Then
        s = Left(s, lastslash - 1) + " - " + Mid(s, lastslash + 1)
      End If
      Cells(row, 10) = s
    End If
  Next
 
  ' scan all subfolders. This function calls itself.
  ' can't use "folder.size", which is denied on "C:\".
  ' and we have to crawl through each folder anyway, looking
  ' for big files.
  Set sflist = folder.SubFolders ' list of subfolders
  For Each sf In sflist ' for each subfolder in the list...
      sfsize = GetFolderSize(sf.Path, depth + 1)
      totalsize = totalsize + sfsize
  Next
 
  ' now log this folder (if it's big) to the spreadsheet
  If totalsize >= bigfile Then
    If depth > 3 Then
      col = 8
    Else
      col = depth + 4
    End If
    row = row + 1
    If folder.IsRootFolder Then
      ' properties are denied on "c:\"
      Cells(row, 1) = ""
      Cells(row, 2) = ""
      Cells(row, 3) = ""
    Else
      Cells(row, 1) = folder.DateCreated
      Cells(row, 2) = folder.DateLastModified
      Cells(row, 3) = folder.DateLastModified
    End If
    mbsize = CLng(totalsize / 1048576#)  ' size in MB
    Cells(row, col) = mbsize
    Cells(row, 9) = mbsize
    Cells(row, 10) = FolderName
  End If
  
  ' Done with this folder
  GetFolderSize = totalsize
End Function
 
 
 
 
 

Thursday, February 24, 2011

One of the best kept secrets of Windows XP is it's built in repair feature!
In previous versions of Windows, correcting an operating system error, or installing a new motherboard, usually meant formating and reinstalling, resulting in loss of all data. Don't worry; Windows XP repair feature won't delete your data, installed programs, personal information, or settings. It just repairs the operating system!
Note: The system repair function will remove any updates you have previously installed that are not included on the CD. Drivers will also be reverted to their original XP versions, as well as some settings (network & performance settings may sometimes be reset to their defaults). It may be necessary to reactivate your Windows XP as well. When finished, you will have to download all of the updates from Microsoft Windows Update, because they are all replaced during repair.
Why would I want to reinstall Windows XP?
1) Can't start Windows XP in safe mode.
2) You have problems caused by a recently installed system update (Windows Update, hotfix, Windows XP service pack, or Microsoft Internet Explorer update).
3) Your problems can't be solved with system restore, or you can't access system restore.
4) You've installed a new motherboard, or made other major hardware changes and need to reinstall Windows.
Let's get started!
Step 1: Rule out hardware issues. Windows Repair will only fix software problems. Hardware issues can also cause boot problems (i.e. bad hard drive, memory, CPU, or power supply).
Step 2: Backup. It's always a good idea to backup your important data before making changes to Windows XP. Relax, if you follow these instructions your data will be perfectly safe.
Step 3: Boot from your Windows XP CD. Insert the Windows XP CD into your computer's CD-ROM or DVD-ROM drive, and then restart your computer. When the "Press any key to boot from CD" message appears on the screen, press a key to start your computer from the Windows XP CD. Can't boot from your CD? Please see the note at the bottom of this page (Configuring Your Computer to Boot from CD).
Step 4: A blue screen will appear and begin loading Windows XP Setup from the CD.
Note: RAID/SCSI/Unsupported UDMA users:
You will be prompted to "press F6 to install any third party SCSI or RAID drivers". Most users will not have to press F6, but if you are running RAID, SCSI or unsupported UDMA controllers, then you will have to have your controller drivers on a floppy disk. If you are unsure whether you have RAID/SCSI, then simply let the CD load without pressing F6.
When completed loading files, you will be presented with the following "Windows Setup" screen, and your first option. Select "To set up Windows XP now, press ENTER". DO NOT select Recovery Console.
Posted Image
When presented with the screen below. press the F8 key to continue.
Posted Image
Next, Windows Setup will find existing Windows XP installations. You will be asked to repair an existing XP installation, or install a fresh copy of Windows XP.
If no installations are found, then you will not be given the option to repair. This may happen if the data or partition on your drive is too corrupted.
Note: If you install a fresh copy, all data on that partition will be lost!
Posted Image
Your almost finished! Windows XP will appear to be installing itself for the first time, but it will retain all of your data and settings. Just follow the prompts, and have your CD-KEY ready if needed.
Do you have more than one system, or lost your CD-KEY? Visit the keyfinder page to retrieve your CD-KEY.
Update: Due to the proliferation of the Blaster and Welchia Worm/Virus be aware that a Repair Install will leave your system vulnerable. You can get infected within seconds. Do not go on line until you have enabled XP's firewall first.
Remember to run Windows Update! (install critical updates first)
-----------------------------
Configuring Your Computer to Boot from CD
Many computers are not configured to boot from the CDROM. If you cannot boot from the CDROM, this is probably due to the boot order of your devices being incorrect. You can change this in the BIOS.
You enter the BIOS from the first screen you see when you turn your computer on. To enter your BIOS, most users here will press the DEL key.
Most Dell, Toshiba, Gateway, Sony & HP systems will press F2.
Compaq users will usually have to press F10.
IBM typically uses F1 or F2.
Other brands may have different keys to press to enter setup, F1, F2, Del, Tab and CTRL+S. If possible see the manual for your computer or motherboard. Also, the BIOS will usually display which button to press to "enter setup" during POST (if it flashes by too fast, press the Pause key).
When you enter the BIOS setup, you need to change the boot order. The CDROM should be setup before the Hard Drive. Each BIOS is different, but here is an example:
Posted Image
Note: If you need assistance with a repair installation, please start a new topic in our Windows XP Forum. This topic is also open for comments, but not all will receive a reply.
IMPORTANT NOTE: After running a repair, you may find that Windows Update refuses to install the most recent 80 patches. This is because the latest version of Windows Update is broken, and doesn't register some DLLs if they're previously been registered (as happens with a repair install). Here's a work around until they get it fixed:

  • Stop the Automatic Updates service. To do this, follow these steps:
    • Click Start, click Run, type cmd, and then click OK.
    • At the command prompt, type the following commands, and then press ENTER after each command:
      net stop wuauserv
      exit
  • Register the file that is used by Windows Update and Microsoft Update. To do this, follow these steps:
    • Click Start, click Run, type cmd, and then click OK.
    • At the command prompt, type the following command, press ENTER after the command, and then click OK when you receive a verification message:
      regsvr32 %windir%\system32\wups2.dll
      Note: for x64 machines regsvr32 %windir%\syswow64\wups2.dll
  • Start the Automatic Updates service. To do this, follow these steps:
    • Click Start, click Run, type cmd, and then click OK.
    • At the command prompt, type the following commands, and then press ENTER after each command:
      net start wuauserv
      exit

DELHI MINIMUM WAGES INCREASED 2011

On Wednesday the Delhi government did something which even the bitterest enemy of the Chief Minister Mrs. Sheila Dikshit will not dare to criticize.

For once accepting that the increased prices have played havoc on the lives of the poor, the Government announced a hike in the minimum monthly wages for both skilled and unskilled laborers. Giving its due to the inflation the hike is nearly 15% and will be effective from Feb 1.

According to the Labour Minister Ramakant Goswami the increase proves the dedication and the determination that the government has for its poor and downtrodden and hopes will be a big relief for them. Going further he hinted another hike in April.

The unskilled workers will now get Rs234 per day instead of Rs 203 per day. After the rates are updated their minimum salary will now be Rs 6084 up from Rs 5278.

For the semi skilled laborers the monthly salary is up from Rs 5850 to Rs 6734. Their daily wages increased to Rs 259 from Rs 225.

For the skilled worker their daily wages have been fixed at Rs 285 from Rs 248 and the monthly salary will move from Rs 6448 to Rs 7410.

The non matriculate workers will get Rs 259 instead of Rs 225 and their monthly salary goes up to 6734 from Rs 5850.

Similarly the matriculate’s daily wages will now be Rs 285per day up from Rs 248 per day. Also their monthly wages would be Rs7410 in placed of Rs 6448.

For Graduates the minimum daily wage is fixed at Rs 310 from Rs 270. Mow their monthly wages would be Rs 8060 instead of Rs 7020.

Wednesday, February 23, 2011

HOW TO BREAK EXCEL PASSWORD

HERE IS A VBA CODE TO BREAK EXCEL PASSWORD BUT IT TAKE A LONG TIME SO I SUGGEST YOU TO USE ANY PROFESSIONAL SOFTWARE TO ENCRYPT THE FILE.   
Sub PasswordBreaker()
    'Author unknown
    'Breaks worksheet password protection.
    Dim i As Integer, j As Integer, k As Integer
    Dim l As Integer, m As Integer, n As Integer
    Dim i1 As Integer, i2 As Integer, i3 As Integer
    Dim i4 As Integer, i5 As Integer, i6 As Integer
    On Error Resume Next
    For i = 65 To 66: For j = 65 To 66: For k = 65 To 66
    For l = 65 To 66: For m = 65 To 66: For i1 = 65 To 66
    For i2 = 65 To 66: For i3 = 65 To 66: For i4 = 65 To 66
    For i5 = 65 To 66: For i6 = 65 To 66: For n = 32 To 126
    ActiveSheet.Unprotect Chr(i) & Chr(j) & Chr(k) & _
        Chr(l) & Chr(m) & Chr(i1) & Chr(i2) & Chr(i3) & _
        Chr(i4) & Chr(i5) & Chr(i6) & Chr(n)
    If ActiveSheet.ProtectContents = False Then
        MsgBox "One usable password is " & Chr(i) & Chr(j) & _
            Chr(k) & Chr(l) & Chr(m) & Chr(i1) & Chr(i2) & _
            Chr(i3) & Chr(i4) & Chr(i5) & Chr(i6) & Chr(n)
         Exit Sub
    End If
    Next: Next: Next: Next: Next: Next
    Next: Next: Next: Next: Next: Next
End Sub

HOW TO RECOVER YOUR DATA

Data Recovery is something that is possible and can be useful and what many users don’t try.There are many data recovery tools which are available for recovering deleted and lost data from various media.MiniTool Power Data Recovery Free Edition is an all in one free data recovery suite has 5 recovery modes which can recover data from Hard Drives, Damaged partitions, Damaged Media like CD/DVD or Memory Cards.
Recovery Methods :
  • Undelete Recovery – To recover files/folders that were intentionally (or accidentally) deleted.
  • Damaged Partition Recovery – To recover files on the re-formatted or damaged partition.
  • Lost Partition Recovery - To recover data from lost/deleted partitions.
  • Digital Media Recovery – To recover data from a digital media. For example: memory card, memory stick, flash drive, mp3 player, iPod. This module focuses on recover photo, video and audio files.
  • CD/DVD Recovery – To recover data from a CD/DVD disk.
minitools power data recovery How To Recover Data From Damaged Media ( Hard Disk, CD/DVD, Memory Cards )