Code to delete rows

  • Thread starter Thread starter Ivor Williams
  • Start date Start date
I

Ivor Williams

A month or so ago, I posted a question about what code I could use to
automatically remove rows in a spreadsheet imported from QuickBooks in which
a cell value is null or blank. I did get a response and the suggested
solution worked perfectly. Since then, I've had to format my hard drive and
lost the code. If the original respondent or anyone else can help with this,
I'd appreciate it.

Ivor
 
Right after you import the spreadsheet run this code:

docmd.runsql "delete from MyTable where MyField is null;"
 
Back
Top