• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Please assist me for delete the particular data

sampath

Member
Hi All,

I have huge data in column wise, I need to delete the particular data from that.
upload_2014-11-20_15-52-37.png

Could you provide any macro for the same.

Regards,
Sampath.S
 
Hi Sampath,

Just an Idea from my Side. How about you try Ctrl+H then type in the criteria Field: *GROUP* and in the Replace Field you simply type a space. Then click on the Replace all button.

If it delivered an unexpected result, then you still have the Ctrl+z option.

Hope this can solve your issue.
 
Hi Yagimli,

When check with your idea, that GROUP character can delete but need to delete the next cell data from GROUP. kindly suggest any function or macro.

Regards,
Sampath.S
 
Hi Asheesh,

I have attached the Sample file here. Kindly provide any macros.

Regards,
Sampath.S
 

Attachments

  • Deleting Samples.xlsm
    16.5 KB · Views: 3
Hi Sampath,

You can call me Mahir. Sorry, could not help you. With VBA I can't help you out.
As for a function: How about this one =IF(OR(ISNUMBER(C4);C4="");"";C4)


Hopefully you'll get a good Macro, would be interesting to see how they will solve this.
 
Hi Sampath,

As Mahir suggested, you can do this without VBA also
couple of steps:
1) Go to find & replace
2) type in find what:
GROUP*

3) leave blank the replace with field:
4) Press replace all

same procedure for your minus values:
find what:
2) -*
4) Replace all

Regards,
 
Hi,

Try this VBA code:

Code:
Sub RemoveDataAfterGrp()
Dim iCol, iRow As Integer
iCol = 1
iRow = 3
Do While Sheet1.Cells(iRow, iCol) <> ""
  If VBA.InStr(1, Sheet1.Cells(iRow, iCol).Value, "Group", vbTextCompare) > 0 Then
  Do
  Sheet1.Cells(iRow, iCol).Value = ""
  iRow = iRow + 1
  Loop Until Sheet1.Cells(iRow, iCol).Value = ""
  Else
  iRow = iRow + 1
  
  End If
  If Sheet1.Cells(iRow, iCol) = "" Then
  iCol = iCol + 1
  iRow = 3
  End If
  
Loop
End Sub

Regards,
Prasad DN
 
Back
Top