Saturday, 20 September 2014

Clear Contents without Clearing Formula

Sub ClearItOut()
Cells.Select
Selection.SpecialCells(xlCellTypeConstants, 1).Select
Selection.ClearContents
End Sub

Merge Sheets in 1 Sheet in Excel

Sub Merge()
Dim ws As Worksheet
ActiveSheet.UsedRange.Offset(0).Clear
For Each ws In ActiveWorkbook.Worksheets
If ws.Name <> ActiveSheet.Name Then
ws.UsedRange.Copy
Range("A65536").End(xlUp).Offset(1, 0).Select
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False
Selection.PasteSpecial Paste:=xlFormats, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False
End If
Next
End Sub

Highlight Duplicate Entry

Sub FindDups ()
   '
   ' NOTE: You must select the first cell in the column and
   ' make sure that the column is sorted before running this macro
   '
   ScreenUpdating = False
   FirstItem = ActiveCell.Value
   SecondItem = ActiveCell.Offset(1, 0).Value
   Offsetcount = 1
   Do While ActiveCell <> ""
      If FirstItem = SecondItem Then
        ActiveCell.Offset(Offsetcount,0).Interior.Color = RGB(255,0,0)
        Offsetcount = Offsetcount + 1
        SecondItem = ActiveCell.Offset(Offsetcount, 0).Value
      Else
        ActiveCell.Offset(Offsetcount, 0).Select
        FirstItem = ActiveCell.Value
        SecondItem = ActiveCell.Offset(1,0).Value
        Offsetcount = 1
      End If
   Loop
   ScreenUpdating = True
End Sub

Delete Spaces in the Cell


Sub TrimBText()
' This module will trim extra spaces from BOTH SIDES.
    Dim MyCell As Range
    On Error Resume Next
        For Each MyCell In Selection.Cells
            MyCell.Value = Trim(MyCell.Value)
        Next
    On Error GoTo 0
End Sub

Delete rows if A1 is Blank

Delete rows if A1 is Blank

Sub DeleteRowsThatLookEmptyinColA()
  Application.ScreenUpdating = False
  Application.Calculation = xlCalculationManual   'pre XL97 xlManual
  Dim Rng As Range, ix As Long
  Set Rng = Intersect(Range("A:A"), ActiveSheet.UsedRange)
  For ix = Rng.Count To 1 Step -1
      If Trim(Replace(Rng.Item(ix).Text, Chr(160), Chr(32))) = "" Then
        Rng.Item(ix).EntireRow.Delete
      End If
  Next
done:
  Application.Calculation = xlCalculationAutomatic
  Application.ScreenUpdating = True
End Sub

Sunday, 14 September 2014

Juliyanaa.. Juliyaana..

    Kaalzaan thaavun mog thuzo haanv karthaam
    Sadaanch tujea mogaak ashethaam
    Dees raath swapnaanth thukaa dekhthaam
    Fudaar chinthun dukham galaithaam ||2||

    Thum mogaa hene thene vaat chamkathaana
    Gumaan deenanyi maaka parvaa thukaa naa
    Haanv thukaa mujench korunk mothinth chinththaanaa
    Kithyaak saandun gelaanyi maaka somzaana

    Juliyanaa.. Juliyaana.. Mogaa mujea.. Juliyaanaa..

    Eksurponan saandlaanyi mu go maaka
    Thuje vine saunsaar naaka
    Borem maagun aadevch karthaam mogaa
    Kaaliz sadaanch chinththelem thukaa ||2||

    Thum mogaa hene thene ... maaka somzaana

    Juliyanaa.. Juliyaana.. Mogaa mujea.. Juliyaanaa..

Illo Illo Soro Piyelo Konkani song

    Illo Illo Soro - Henry D'souza
    Illo illo illo illo soro piyelom
    illo illo munon maaka chod chod zaalo
    Chod chod zaathana mujea thoklek chodlo
    Kithle paavtin soro piyevn ghataraanth podlon ||2||

    Ek dees soro piyevn ghara yethalom
    Shidiyo chodun ghar mun chinthun daar bodoithalom
    Chedvanchem them hostel munon nenaa aslolom
    Chor chor munon maaka polisaank dilo ||2||
    Polisani maaka maarlo anim jailaanth lotlo
    Amaal firvaathana muzo maanddo thaasllo ||2||

    Illo illo ..ghataraanth podlon

    Baaraa voraar raathik haanv ghara paavullom
    Daaraar mujea Raagaar haanv khoto ghaalthalom
    Daar ugaadthana re ek daadlo aslolo
    Daadlyak polevn raag mujea thoklek chodlolo ||2||
    Daadlyaak haanvem maarlo thaacho maanddo futailo
    Polenvk gelyaar muzoch tho maanv aasllo ||2||

    Illo illo ..ghataraanth podlon

    Ek dees tight zaavun ghara yethalom
    lokun lokun vaat chukon maargaar podlom
    Baail mujhi kiss dithaa munon swapnelom
    Polenvk gelyaar thond mujhem peto lenvthaalo ||2||
    Kushin bhava vodlo ek redo raavullo
    Bhathen munon chinthun mujhi lungi chaabthaalo ||2||

    Illo illo ..ghataraanth podlon ||2||
    Kithle paavtin soro piyevn ghataraanth podlon
    Kithle paavtin soro piyevn ghataraanth podlon.....