Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Delet Fields

Status
Not open for further replies.

spinheiro

IS-IT--Management
Jun 18, 2003
4
PT
Hi,

How can I delet a field in VB access if that field only have null values?

Thanks in advanced
Sofia
 
You you want to delete an entire column?

You would do that in the table schema.

Are you talking about deleting rows?

You could do that with a DELETE query, quallifying the rows that would be selected for delete.

Not really sure what you are looking for???

Skip,
Skip@TheOfficeExperts.com
 
Yes, I want to delete an entire column, but only if all the values are null. I want to create a command button to execute this action so that future users only have to do a click. I thought to do this in VB, something like (don't work):
-------------------------------------------------------
While N_Reg <> 0
If Not IsNull(rst!CAF) And Not IsEmpty(rst!CAF) Then
conta = 1
End If
N_Reg = N_Reg - 1
rst.MoveNext
Wend
If conta = 0 Then
Fields.Delete CAF
End If
--------------------------------------------------------
thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top