Create a short way to save typing script over and over....

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • frankrentef

    Create a short way to save typing script over and over....


    I have a statement "url = 'http://xyzserver/'" so in my code every
    time I need to use xyzserver I state "url +...."

    What I' m now trying to do is create a call to a login process. The
    script for the login process is below. I'd like to call "adminlogin "
    and not have to keep entering the same several lines of script each
    and everytime (I'm testing various login functions and rule changes.)

    I'm a newbie, can someone walk me through this?

    THNX



    #Login to ISeDeposit Admin

    ie.navigate (url + 'isweb/admin/default.aspx')
    ie.textBoxSet ('AdminLogin1:U sername','Admin ')
    ie.textBoxSet ('AdminLogin1:i nputPassword',' Password')
    ie.buttonClick ('AdminLogin1:b tnLogin')
  • Sean DiZazzo

    #2
    Re: Create a short way to save typing script over and over....

    On Aug 7, 11:56 am, frankrentef <frankren...@ya hoo.comwrote:
    I have a statement "url = 'http://xyzserver/'"  so in my code every
    time I need to use xyzserver I state "url +...."
    >
    What I' m now trying to do is create a call to a login process.  The
    script for the login process is below.  I'd like to call "adminlogin "
    and not have to keep entering the same several lines of script each
    and everytime (I'm testing various login functions and rule changes.)
    >
    I'm a newbie, can someone walk me through this?
    >
    THNX
    >
    #Login to ISeDeposit Admin
    >
    ie.navigate (url + 'isweb/admin/default.aspx')
    ie.textBoxSet ('AdminLogin1:U sername','Admin ')
    ie.textBoxSet ('AdminLogin1:i nputPassword',' Password')
    ie.buttonClick ('AdminLogin1:b tnLogin')
    def login(url):
    ie.navigate (url + 'isweb/admin/default.aspx')
    ie.textBoxSet ('AdminLogin1:U sername','Admin ')
    ie.textBoxSet ('AdminLogin1:i nputPassword',' Password')
    ie.buttonClick ('AdminLogin1:b tnLogin')


    login("http://xyzserver/")

    Maybe?

    ~Sean

    Comment

    Working...