Results 1 to 8 of 8

Thread: How can we parameter a Web link

  1. #1
    Junior Member
    Join Date
    Sep 2007
    Answers
    6

    How can we parameter a Web link

    How can we parameterize the link? The scanarios is as follows:

    1) Clink on a link and enter the page
    2) there will be table which contains the fields like "UsedID,Address,ZIP"
    3) Close the page

    How can we automate this scenario?

    Thanks in advance.


  2. #2
    Junior Member
    Join Date
    Sep 2007
    Answers
    6

    Re: How can we parameter a Web link

    Can anyone please solve the above Scenario


  3. #3
    Junior Member
    Join Date
    Mar 2008
    Answers
    8

    Re: How can we parameter a Web link

    hai iliaz...is that the link in a table..if its in a table then u can use the getcelldata...and click on the link...becoz the link will always appear in a particular cell...


  4. #4
    Expert Member
    Join Date
    Oct 2007
    Answers
    375

    Re: How can we parameter a Web link

    Hi Iliaz,

    can you please explain as to why you are looking at parameterizing the Link.
    Coz I guess the Link name is going to remain the same for every iteration.

    Incase you are talking of different links existing and clicking on each would lead to page with a Table displaying some fields, I guess it makes sense to parameterize the link click action.

    NOTE : Only incase all the specified links occur in the same page, would you make sense to parameterize.

    Include all Link Object names into your Local or Global Datasheet. The remaining operation prior to clicking and after clicking the link will remain the same.

    The syntax would be - Browser("").Page("").Link(DataTable("ColumnName",dtLocalSheet)

    You could also add checkpoints or simply use getCellData to validate the fields displayed in the webpages resulting from clicking on the links.

    Let me know if this is what you are looking at.

    cheers......


  5. #5
    Junior Member
    Join Date
    Mar 2008
    Answers
    4

    Re: How can we parameter a Web link

    'Assume that the names of WebLinks present in the page are stored in 'LnkName' unser LocalSheet
    'As we can identify the Weblink Using its 'name' property

    set Lnk = Description.Create
    Lnk("micClass").Value = "Link"

    rcnt = DataTable.GetRowCount

    For i = 1 to rcnt
    DataTable.setCurrentRow(i)
    Lnk("name").Value = DataTable("lnkName",dtLocalSheet)
    Lnk.Click
    'Copy The values in Table and store in dataTable
    'Close the Window
    Next


  6. #6
    Junior Member
    Join Date
    Dec 2007
    Answers
    1

    Re: How can we parameter a Web link

    Hi,
    I need some information about passing the dynamic value in to weblink.
    Mine is a web application. The script what i have is like this:
    'Browser("Login").Page("Application").Frame("ScopeFrame").Link("DC4303788(Active)").Click
    In which the data DC4303788" in Link method will get changed dynamically. I am able to get the value "DC4303788" in to a variable using getROproperty method. Now, instead of placing the value DC4303788 in to link method, i want to pass the variable where the value DC4303788 which i have.

    Is it possible to pass any dynamic value into link method?
    Pls help me out in this.


  7. #7
    Expert Member
    Join Date
    Apr 2008
    Answers
    1,859

    Re: How can we parameter a Web link

    Hai friend,

    Just try this

    Method 1

    dynamic1=Browser("Login").Page("Application").Frame("ScopeFrame").Link("html tag:=A").GetRoProperty("innertext")
    Browser("Login").Page("Application").Frame("ScopeFrame").Link(dynamic1).Click

    Method 2

    Use regular expression.

    Here I assume all link name is starting with DC so I am adding regular expression given below

    Browser("Login").Page("Application").Frame("ScopeFrame").Link("DC.*").

    Let me know if any issues exists

    Thanks
    Deepa


  8. #8
    Junior Member
    Join Date
    Jan 2008
    Answers
    5

    Re: How can we parameter a Web link

    Deepa,

    I have similar dynamic link issue where the name of the link changes.i tried both the ways u said but none of them worked for me . when i used the first method

    dynamic1=Browser("Browser").Page("TREX_5").Frame("Frame_2").
    Link("html tag:=A").GetRoProperty("text")
    Browser("Browser").Page("TREX_5").Frame("Frame_2").Link(dynamic1).Click

    I see an error General Run time error (2147220989)

    when i tried the second method i get this error

    The "COPY.*" Link object was not found in the Object Repository.
    Check the Object Repository to confirm that the object exists or to find the correct name for the object.


    Can you please let me know how to fix the error.Thank you

    Lakshmi


  9.  Sponsored Ads
    Ad


     

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Applying for a job can be a stressful and frustrating experience, especially for someone who has never done it before. Considering that you are competing for the position with a at least a dozen other applicants, it is imperative that you thoroughly prepare for the job interview, in order to stand a good chance of getting hired. That's where GeekInterview can help.
Interact