Need help with SendKeys function

rlill

New Member
Joined
Mar 5, 2016
Messages
16
Hello

I have developed an VBA application that is able to get coordinates from Google API if user inserts address into the right cell. After finding coordinates it can find nearest another coordinates from another database. That all works well. Now if I tried my application in another computer in another network there occured a problem. After inserting like 50 addresses I only get back half of the coordinates in irregular order. Only way I can get all the coordinates is to press "ENTER" in every address cell manually, so it requests the data from Google one by one. And so it works in my another computer. But if there is 50 or 150 and so on addresses it is not very efficient way to work with so. And now comes my question. Is it possible to write a macro that is able to check the value of the cell and if it says "#VALUE!" then hit "ENTER" and move on to next cell.

Look the picture. Some of the cells contains "#VALUE!". If I hit enter that cell then it gets the coordinate.
I would appreciate it a lot if somebody could help me find a solution to my problem.
Capture.PNG
 

Excel Facts

Repeat Last Command
Pressing F4 adds dollar signs when editing a formula. When not editing, F4 repeats last command.
Or there is some better way how to solve this problem? [h=2]SendKeys function was just the first idea that popped.[/h]
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,178
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top