From: Maelito77 on
Hi guys
I have never used VBS script before but I would like to use it to launch a
Citrix WI page and to login in to the website.
I have using XenApp5.0 FR2 with WebInterface 5.2.

I have this script but this does not work on login, I can open the website
but then I get an error:


strEmail = "myusername"
strPass = "mypassword"
Set objIE = CreateObject("InternetExplorer.Application")
objIE.Visible = True
objIE.Navigate "http://mywebinterface"
While objIE.Busy = True
WScript.Sleep 100
Wend
While objIE.ReadyState <> 4
WScript.Sleep 100
Wend
objIE.Document.all.msuLoginName.value = strEmail
objIE.Document.all.msuPassword.value = strPass
objIE.Document.all.msuLoginSubmit.Click


Thanks, Maelito

Maelito
From: Tom Lavedas on
On Jan 19, 12:21 pm, Maelito77 <Maelit...(a)discussions.microsoft.com>
wrote:
> Hi guys
> I have never used VBS script before but I would like to use it to launch a
> Citrix WI page and to login in to the website.
> I have using XenApp5.0 FR2 with WebInterface 5.2.
>
> I have this script but this does not work on login, I can open the website
> but then I get an error:
>
> strEmail = "myusername"
> strPass = "mypassword"
> Set objIE = CreateObject("InternetExplorer.Application")
> objIE.Visible = True
> objIE.Navigate "http://mywebinterface"
> While objIE.Busy = True
>  WScript.Sleep 100
> Wend
> While objIE.ReadyState <> 4
>  WScript.Sleep 100
> Wend
> objIE.Document.all.msuLoginName.value = strEmail
> objIE.Document.all.msuPassword.value = strPass
> objIE.Document.all.msuLoginSubmit.Click
>
> Thanks, Maelito
>
> Maelito

Without knowledge of the page being accessed it is impossible to be
accurate in any response. Also, "does not work" isn't much to go on.
I think posting the source of the parts of the page you are
referencing above would be helpful, along with a more detailed
description of the mode of failure, symptoms, error messages, etc.
Then someone might be able to comment.
_____________________
Tom Lavedas
From: cothomas on
This code works. The only caveats is that you need to make certain
the form names match. For example try the code below. If it is still
not working, please post the html code of the website.

strSearch = "vbscript"

Set objIE = CreateObject("InternetExplorer.Application")
objIE.Visible = True
objIE.Navigate "http://www.google.com"
While objIE.Busy = True
Wscript.Sleep 100
Wend

While objIE.ReadyState <> 4
Wscript.Sleep 100
Wend

objIE.Document.All.q.Value = strSearch
objIE.Document.All.btnG.Click



On Jan 19, 12:21 pm, Maelito77 <Maelit...(a)discussions.microsoft.com>
wrote:
> Hi guys
> I have never used VBS script before but I would like to use it to launch a
> Citrix WI page and to login in to the website.
> I have using XenApp5.0 FR2 with WebInterface 5.2.
>
> I have this script but this does not work on login, I can open the website
> but then I get an error:
>
> strEmail = "myusername"
> strPass = "mypassword"
> Set objIE = CreateObject("InternetExplorer.Application")
> objIE.Visible = True
> objIE.Navigate "http://mywebinterface"
> While objIE.Busy = True
>  WScript.Sleep 100
> Wend
> While objIE.ReadyState <> 4
>  WScript.Sleep 100
> Wend
> objIE.Document.all.msuLoginName.value = strEmail
> objIE.Document.all.msuPassword.value = strPass
> objIE.Document.all.msuLoginSubmit.Click
>
> Thanks, Maelito
>
> Maelito