That is (part of) the path for 32 bit applications installed on 64 bit Windows. In the “32 Bit” windows version there is no need for the …/program files (86)/… code. Your paths in the example code for copying are missing some slashes,, but they are present in the screen capture. The code needs a little tweaking, but I found it also works for FireFox, therefore probably any browser or application.
#HOW TO SEARCH A PAGE FOR TEXT IN CHROME HOW TO#
'chromePath = "C:Program Files (x86)GoogleChromeApplicationchrome.exe"Įnd Sub How to use this VBA Code to Search on Google 'Uncomment the following line for Windows 64 versions and comment out Windows 32 versions
Shell (chromePath & " -url " & search_string) 'Uncomment the following line for Windows 32 versions and comment out Windows 64 versionsĬhromePath = "C:Program Files (x86)GoogleChromeApplicationchrome.exe"
'Uncomment the following line for Windows 64 versions and comment out Windows 32 versions'ĬhromePath = "C:Program FilesGoogleChromeApplicationchrome.exe" Search_string = Replace(search_string, " ", "+") Query = InputBox("Enter here your search here", "Google Search") Here is the code below which you can use to search on Google using Chrome. VBA Code to Open Google Chrome for Search You can add this code to your personal macro workbook and use it anytime when you need to search for something on Google. In my list of useful macro codes, I have a code which you can use to perform a search query on Google using Chrome.Īnd today, I’m gonna share that code with you.