Selecting an option value within a frame - excel

OK. I've been playing with this for way too long now. I am doing a web-scrape using the chrome-driver for Selenium and VBA. I am able to paste elements from my Excel file onto the page (includes switching frames), switching to a next window, getting results and back to original webpage and moving to next row in Excel, etc. My problem is I have yet to be able to discover the proper method to select an item in a drop-down box. Any direction would be greatly appreciated.

Related

Powerpoint / Excel VBA Formatting multiple duplicate slides / selecting images / mouse click

Essentially I have around 90 slides that all have the same format of 5 images pasted from an excel sheet through a different macro and I'd like to have them moved around to obviously tidy up the slides.
I have macros to move all of the objects to the right places and crop one of them.
The only issue I have is how to get the code to select the correct image.
My thoughts were to have the mouse click in certain locations. I have managed to get a macro tomove the mouse to the correct position but it does not click / select the image in that location properly.
It would be easier to select the images possibly by name, I am unsure how to do this and also a few of the images have the same object names of 'image1' 'image2' so I'm unsure if that would work. If anyone has any suggestions or would like more details :)

Copying data from a dropdown menu to a seperate sheet as a report using VBA

Complete beginner with VBA and I think I'm doing something majorly wrong.
So context;
Creating a user friendly sheet to do checks on items etc. To keep it as simple as possible for other people I've decided to use drop down menus to input the majority of the data and tick boxes to say when the check has been done.
From here I want to add a big old button that will transfer the data from the cells, dropdown menu and tick boxes to another sheet or workbook.
I would also need the sheet or workbook to place the date the checks were done and create a new line with the information. So that I can look at a single sheet and see the wear and tear on the equipment in one form. (layout of this can be sorted out after wards just how to get it to go to a blank line etc.)
And finally to save the document.
drop down information is linked from another sheet within the workbook.
Now I've tried some code to work it out myself and it either doesn't copy the data as the cell is blank (drop down menus) or it just shoots up an error on the VBA page.
Could anyone assist in helping me work this code out? Even if its just the command syntax's that I would need to use.
Thanks in advance
Peter

How to delete a large number of command buttons in excel

I have a macro that I have designed to retrieve information from the internet and then to process that information into formats I want. My first worksheet in the workbook functions as my command page and all of the subsequent worksheets are populated based on what I tell the command page I want.
I have assigned control buttons on the command page to all of the various functions I want the macro to execute on the data retrieved from the web so I can select which functions I want applied. However, I believe that somewhere along the way I told my code to make copies of 1 certain command button.
There are now over 7000 command buttons for one function. Thank fully they are all stacked on one another so it isn't obvious, however it is starting to slow my excel down.
Is there any way to manage all of you buttons and then to select the ones you wish to delete?
Maybe a macro that deletes all duplicate command button names would do the trick? Before I tried this method, I wanted to see if there was an easier fix to my problem.
This should work for you:
Shift+Ctrl+Click on the button to select it
Press Ctrl+a to have it select all of them
Then Ctrl+Click the button to de-select the top-most button
Press the Del key to delete all selected objects.

Excel Listbox in a Sheet with FreezePanes

I have an Listbox Multiselect ActiveX control in a Sheet with Freeze Panes. The problem is that when I try to select items the mouseover icon is the standard excel cross instead of the arrow. I know that this question was asked before, but I didn't find any answer.
Thank u in advanced for help
I tested, and I came up with a few interesting observations.
In the ribbon, go to the developer tab. Make sure that the Design
Mode is not on.
When I first froze panes on the sheet, the freeze line went through the listbox I created. This caused the behavior you are describing with the cross-hairs and being unable to select.
Then I moved the listbox. Still same problem. I tried clicking on various cells around the sheet and in the ribbon area, with no change in behavior.
When I clicked to another sheet and back again, it started working as expected. Normal pointer mouse. I could select multiple, and unselect as needed.
Based on what I've tried, it seems that making sure Design Mode is off, and clicking to another sheet and back again may fix the problem.

Loading Image from URL in Excel

Basically I have a gigantic excel spread sheet with over 20,000 URL's. It would be very inefficient of me to click on each link to check the image. Instead I was wondering if I could take the url from one cell and load the image into a different cell. This of course would have to be a loop as I have so many images to load. So far I found a thread on this already but I have no idea how to implement this code.
How to get images to appear in Excel given image url
If someone could tell me how to use this code that would be great and you will also save my sanity. Thanks!
While your Excel sheet is open, press ALT+F11 (Edit: Not Ctrl)
This will open the Visual Basic editor. From there, locate the project explorer to the left side of the screen. It should appear something like VBAProject (YourWorkBookName.XLS)
right click it and select Insert -> Module.
You should see a blank white space for you to put code in. Just paste the code you found from the other post, but make sure you paste it inside a SUB definition , like this:
Sub AnyNameCanBeChoosen()
' Paste your code Here
End Sub
Then press F5 to execute your code.

Resources