Remove part of an inout element VBA HTML

TheEnergyMan

New Member
Joined
Mar 12, 2019
Messages
12
Hi,

In order to automate a site and get around using the date picker ive found I can remove the 'read only' part of the input on the site which allows me to input the date, however i cant seem to automate this.

Im trying to change :

<input id="fromDatePicker" placeholder="" readonly="readonly" style="width:130px" type="text" class="hasDatepicker">


to:

<input id="fromDatePicker" placeholder="" style="width:130px" type="text" class="hasDatepicker">


Ive tried using ie.document.getattributebyID("fromDatePicker").removeattribute("readonly") But i cant see, to get it to work.

for reference I'm using internet explorer

any help with this matter is appreciated, Thanks!
 
Last edited:

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.
Try this:
Code:
    IE.Document.getElementById("fromDatePicker").removeAttribute ("readonly")
 
Upvote 0

Forum statistics

Threads
1,215,340
Messages
6,124,382
Members
449,155
Latest member
ravioli44

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