Missing or null object

Hello!!

first at all, Sorry for my bad inglish, im Brazillian.

 

So… I need create a automated script that creates an IE object and handles the elements in web page…

$ie = new-object -ComObject “InternetExplorer.Application”

My problem is: I can create that object in all other pages, i can get elements by Id, Tag, Class, etc … but, in determined page i can’t. Looks like the object after addressing the page “$ie.navigate($page)”, that is null or empty.

give me an error:

PS C: \ Users \ thalys> $ ie.Document | get-Member
get-Member: You must specify an object for the Get-Member cmdlet.
In the line: 1 character: 16
+ $ ie.Document | get-Member
+ ~~~~~~~~~~
    + CategoryInfo: CloseError: (:) [Get-Member], InvalidOperationException
    + FullyQualifiedErrorId: NoObjectInGetMember, Microsoft.PowerShell.Commands.GetMemberCommand
PS C: \ Users \ thalys> $ ie.Document.getElementById ("abrirModalLogin"). Click
You cannot call a method on a null value expression.
In line: 1 character: 1
+ $ ie.Document.getElementById ("abrirModalLogin"). click
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~
    + CategoryInfo: InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId: InvokeMethodOnNull

if need know what that page, ask me.

 

check if the page is loaded as expected.
set $ie.visible = $true to open the hidden web browser.

yes, the page loads and when i give the comand navigate, the cursor loads, (seems to execute the comand), but when write the others commands, give me thats errors in topics… I can catch any log to analyse this object ?
The page run some Framework, does it impact anything ?