Re: Using New VBA code



Why are you RE-posting the same question?

--
Don Guillett
Microsoft MVP Excel
SalesAid Software
dguillett1@xxxxxxxxxxxxx
"Kris" <Kris@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message news:1021FC7E-0AED-4662-9BEA-6E7A0BBB493A@xxxxxxxxxxxxxxxx
I am trying to set up a macro to delete rows if some of the columns in the
row do not contain data.

here is the code that I am using:

Sub DeleteBlankRows2()
'Deletes the entire row within the selection if _
some of the cells WITHIN THE SELECTION contain no data.

On Error Resume Next

Selection.EntireRow.SpecialCells(xlBlanks) . EntireRow.Delete

On Error GoTo 0

End Sub

The columns have pick lists build in some, but if I leave the pick list
blank I want it to delete the entire row. When I run the macro I get a
Syntax Error that says something is not set up right.

Can anyone help me?


.



Relevant Pages

  • RE: Using New VBA code
    ... Luke M ... "Kris" wrote: ... some of the cells WITHIN THE SELECTION contain no data. ... The columns have pick lists build in some, but if I leave the pick list ...
    (microsoft.public.excel.worksheet.functions)
  • Re: multiple pick from drop-down list
    ... Each sheet will have anywhere from a couple pay items up to ... selection model is the accidental over-writing of existing data. ... We have setup drop-down lists through data ...
    (microsoft.public.excel)
  • Re: Asp.net Dropdownlist selected index in changed
    ... back it will lose selection from fifth to first item in the list. ... The selected index of first two lists remain same but only thirds are ... private void BindSectionDropDownlist() ... Code for Searching according to the selection of third dropdown ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: multiple pick from drop-down list
    ... Let all your friends at NJDOT know that you are still working ... selection model is the accidental over-writing of existing data. ... We have setup drop-down lists through ...
    (microsoft.public.excel)
  • Re: Asp.net Dropdownlist selected index in changed
    ... The selected index of first two lists remain same but only thirds are ... private void BindSectionDropDownlist() ... Code for Searching according to the selection of third dropdown ...
    (microsoft.public.dotnet.framework.aspnet)

Loading