writing a script

B

brokerluke

how would i write a script that i can change as needed
that will do
find "test"
replace all "test" with a blank field or deleting it.
just like you would use the find button by clicking and typing in the info..
i'm looking for automation

i have to do this manually now and its very painstaking as i have to do this
5-6 times every time i import data..

what would do macro?.. VB script look like for such a task?
 
P

pietlinden

how would i write a script that i can change as needed
that will do
find "test"
replace all "test" with a blank field or deleting it.  
just like you would use the find button by clicking and typing in the info..
i'm looking for automation

i have to do this manually now and its very painstaking as i have to do this
5-6 times every time i import data..

what would do macro?.. VB script look like for such a task?

use an update query

UPDATE MyTable
SET MyField=Null
WHERE MyField = 'Test';

If you had to do a bunch of them, use

DBEngine(0)(0).Execute "UPDATE MyTable SET MyField=Null WHERE MyField
= 'Test';", dbFailOnError
DBEngine(0)(0).Execute sqlStatement2
DBEngine(0)(0).Execute sqlStatement3
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top