html - ie.Document.getElementById("pass").click doesn't work -
can't login. sure login , password correct. website does't accept data. typed manually work, vba code can't login. no vba crush. ideas?
html code:
<input type="text" name="username" id="username" ng-model="user.username" class="form-control ng-dirty ng-valid-parse ng-valid ng-valid-required ng-touched" placeholder="login" required="" autofocus=""> <input type="password" name="password" id="password" ng-model="user.password" class="form-control ng-dirty ng-valid-parse ng-valid ng-valid-required ng-touched" placeholder="hasło" required="" autocomplete="off"> <button class="btn btn-lg btn-primary btn-block" type="submit" id="btn-submit">zaloguj się</button>
vba code:
sub lsi() dim a, b string = "aaa" b = "bbb" set ie = createobject("internetexplorer.application") my_url = "https://lsi.slaskie.pl/#/login" ie .visible = true .navigate my_url while ie.readystate <> 4 , ie.busy doevents loop dim starttime single starttime = timer while timer - starttime <= 2 loop end ie.document.getelementbyid("username").value = ie.document.getelementbyid("password").value = b ie.document.getelementbyid("btn-submit").click until not ie.busy , ie.readystate = 4 doevents loop end sub
Comments
Post a Comment