Email Embedded Microsoft Browser Map

Galius

New Member
Joined
Jul 27, 2018
Messages
30
Hey Guys,

So I have a basic spreadsheet here where I put addresses and then click View Map and it'll load the map in an embedded Microsoft Web Browser ActiveX Control. All I want to do is right a script to basically screenshot that embedded map then paste it in an email to send.


I've uploaded the sheet to the google drive above. I tried posting images but it kept telling me too large even though they were only 250kb.
 

Excel Facts

Ambidextrous Undo
Undo last command with Ctrl+Z or Alt+Backspace. If you use the Undo icon in the QAT, open the drop-down arrow to undo up to 100 steps.
Upvote 0
It actually takes a snapshot on the currently active window. So if the button is on the userform, then it will take a snapshot of the userform. If the button is on the worksheet, then it will take a snapshot of the worksheet. It should be possible to get a snapshot of just the webbrowser control, but I would need to check. I tried checking your file from the original post, but it didn't have a userform in it. Have you since updated it?
 
Upvote 0
O
It actually takes a snapshot on the currently active window. So if the button is on the userform, then it will take a snapshot of the userform. If the button is on the worksheet, then it will take a snapshot of the worksheet. It should be possible to get a snapshot of just the webbrowser control, but I would need to check. I tried checking your file from the original post, but it didn't have a userform in it. Have you since updated it?
Oh! Sorry mate mine actually didn't have a userform just a Microsoft Web browser control, but it should still be able to to work off that shouldn't it?
 
Upvote 0
Ahh - so where is the webbrowser control? Did you draw it directly on the worksheet?
 
Upvote 0
Ahh. Sorry if it seems like a stupid question - it's just I forgot that you can do that with 32bit Excel and you user info details didn't show your version of Excel.
I'm using 64bit - Excel doesn't allow us to draw the webbrowser onto the worksheet anymore, so when I open your workbook, all I see is the table and some buttons. When I try and click on one of the View Map buttons, it produces an error - Excel strips the control from the workbook when I try and open it.

But anyway, it may not matter. Although I like to test these things properly myself on my system at home first (and I obviously can't here), It should still be the same method of taking the snapshot as what I was thinking of adding to the Userform version with a slight tweak. We will have to try it and see. Let me look at it again later today.
 
Upvote 0
Ahh. Sorry if it seems like a stupid question - it's just I forgot that you can do that with 32bit Excel and you user info details didn't show your version of Excel.
I'm using 64bit - Excel doesn't allow us to draw the webbrowser onto the worksheet anymore, so when I open your workbook, all I see is the table and some buttons. When I try and click on one of the View Map buttons, it produces an error - Excel strips the control from the workbook when I try and open it.

But anyway, it may not matter. Although I like to test these things properly myself on my system at home first (and I obviously can't here), It should still be the same method of taking the snapshot as what I was thinking of adding to the Userform version with a slight tweak. We will have to try it and see. Let me look at it again later today.
Thanks Dan, let me know how you go. It actually didnt work for me either at first, had to edit the registry to make it work. You can see that HERE if you'd like. :)
 
Upvote 0
So much for those security concerns.. LOL. Thanks. I'm not a huge fan of ActiveX controls on worksheets, but it's useful to at least have the option. While you're there, do you know what version of Excel you're using and its bitness (32 bit or 64 bit)?
 
Upvote 0

Forum statistics

Threads
1,223,236
Messages
6,170,912
Members
452,366
Latest member
TePunaBloke

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