T
thebiggermac via AccessMonster.com
My company inherited a database that has numerous blank data fields. In order
to make the project work correctly the blank field(s) was populated with the
word "None". This had the desired effect and the project screamed along
nicely.
Now the powers that be want the word "None" replaced with a blank. The
problem is that removing the word causes the project to fail. By failure I
mean when running the query(s) it skips data (the blank fields) which in turn
produces erroneous reports (a lot of data is missing). In Access we are
getting around the issue with conditional text formatting (Access 2003, we
literally white out the text). BUT the data is exported to Word. When that
happens the word "None" appears in the Word doc.
The missing data (what we populated with the word "None") is generally
located in one specific field (about 98% of the time), which is why it seems
to me that the solution is to replace the word "None" with a null value, such
as a blank space. I know this can be done via VBA. Most likely the code would
be in a module and available as Public to the entire database to affect the
odd fields where data is also missing. I'm almost positive a Private_sub
won't work (but I could be wrong). It may be that I have to create both. I’m
not sure.
We first tried to correct the issue using queries but with no luck. Hence I
believe that our only option is VBA code. The trouble is I don't have enough
knowledge of VBA to write the code to replace "None" with a null value (blank
space). Any help and/or suggestions would be most appreciative. Other
suggestions would also be appreciated.
to make the project work correctly the blank field(s) was populated with the
word "None". This had the desired effect and the project screamed along
nicely.
Now the powers that be want the word "None" replaced with a blank. The
problem is that removing the word causes the project to fail. By failure I
mean when running the query(s) it skips data (the blank fields) which in turn
produces erroneous reports (a lot of data is missing). In Access we are
getting around the issue with conditional text formatting (Access 2003, we
literally white out the text). BUT the data is exported to Word. When that
happens the word "None" appears in the Word doc.
The missing data (what we populated with the word "None") is generally
located in one specific field (about 98% of the time), which is why it seems
to me that the solution is to replace the word "None" with a null value, such
as a blank space. I know this can be done via VBA. Most likely the code would
be in a module and available as Public to the entire database to affect the
odd fields where data is also missing. I'm almost positive a Private_sub
won't work (but I could be wrong). It may be that I have to create both. I’m
not sure.
We first tried to correct the issue using queries but with no luck. Hence I
believe that our only option is VBA code. The trouble is I don't have enough
knowledge of VBA to write the code to replace "None" with a null value (blank
space). Any help and/or suggestions would be most appreciative. Other
suggestions would also be appreciated.