Fill Empty Cells Between Entries

leo25031

New member
Local time
Today, 06:09
Joined
Apr 21, 2009
Messages
3
Hi,

I have a table which contain the clients name and on the next row it has the further details, basically I would like to fill the empty cells with the cell value (field "Client") above until a new cell value is found so it will look like:

North Bay
North Bay
North Bay
North Bay
North Bay
South Bay
South Bay..

Thank you
 
Have you tried using a default value in the properties of the field .

If you are using a Form
And depending when you wish the empty cells to be populated wth the word client , you could try the following in the Forms Close event procedure.:
If Me.Name of Field = "" Then
Me.Name of Feild = "Client " ' or whatever data you wish to enter
End If
 
Whenever you have "duplicate" data, you need to examine your table structure. This looks like it should be two tables rather than one. tblClient will include the clientID, name, address, etc. and the details table will have only the ClientID which will point to the client table.

If this data was imported from Excel, go back to Excel and fix it before you import it.

If you have to fix it in Access, the table MUST have some ID such as an autonumber that is unique and sequential because queries are unordered sets and so to get the rows in a particular sequence, they MUST be sorted. You can then write a code loop that copies the client value from the previous row if the current row is empty.
 

Users who are viewing this thread

Back
Top Bottom