VBA HTML - accessing link with href="javascript:void(null)"

MB95

New Member
Joined
Sep 24, 2021
Messages
7
Office Version
  1. 2016
Platform
  1. Windows
I am attempting to use VBA code to navigate through multiple links with each taking me to a new destination each time (this from a VBA standpoint I understand).

I have encountered a link with href="javascript:void(null)"...

My question revolves around trying to dig deeper into the URL that sits behind this href.

I was thinking that if I could determine this URL it would save me the steps of having to click multiple links to get to my end destination...

The HTML is below:

<a name="SectionElements" onclick="return DashboardReportLink('saw.dll?Go&amp;Path=%2fshared%2fXXXX%20XXXXX%20XXXXX%2fELXXX%20-%20ED%20Visits%20by%20XXXX%20of%20Stay&amp;Action=promptstart&amp;style=Custom&amp;Options=mrd', 'd:dashboard~p:usdl82p418i15ed6~r:pm1vepvlehbshlkn','Dashboard&amp;PortalPath=%2fshared%2fBackOffice%20Dashboard%20Group%2f_portal%2fBack%20Office&amp;Page=XXXX%20and%20XXXXX', true)" href="javascript:void(null)">XX803 - XX XXXX XX XXXX XX XXX</a>

With the HTML after "onclick" I guess I'm essentially asking if it is possible to access this without prompting VBA to click?

Thanks!
 

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.

Forum statistics

Threads
1,215,645
Messages
6,125,995
Members
449,279
Latest member
Faraz5023

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