SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 7 of 7
  1. #1
    Junior Member
    Join Date
    Apr 2008
    Posts
    14
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    How to get column name&Cell value using datatatabl

    How to get cloumn name(Header Name ) and cell value for example header anmes are in first row and i am in third row and second column that means cell(3,2), now i want that column header name and Cell value
    Plz send script as early as possible.


    Thanks,
    ..Vasu

  2. #2
    Member
    Join Date
    Oct 2007
    Posts
    40
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to get column name&Cell value using datatatabl


    Hi Vasu,

    Using the function called getCellData, you can capture the table heading and particular cell data.

    Here it goes,

    colheadingvalue=Browser("").Page("").WebTable(""). getCellData(1,2)
    msgbox(colheadingvalue)
    colcelldata=Browser("").Page("").WebTable("").getC ellData(3,2)

    For more information, get into to QTP help.

    Regards,
    Vasanth

  3. #3
    Junior Member
    Join Date
    Apr 2008
    Posts
    14
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to get column name&Cell value using datatatabl

    from excel sheet

  4. #4
    Junior Member
    Join Date
    Apr 2008
    Posts
    14
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to get column name&Cell value using datatatabl

    From excell sheet

  5. #5
    Senior Member
    Join Date
    Dec 2006
    Location
    Germany, Dresden
    Posts
    1,536
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to get column name&Cell value using da

    importing excel sheet into QTP and use DataTable-object....

    for hints and examples use the online help of QTP
    http://qcmt.pc-polis.de

    de omnibus dubitandum

    For all Questions: Please be sure to take a look at the QTP Manual before posting any Questions, thanks for doing this

  6. #6
    Senior Member
    Join Date
    May 2005
    Location
    Chennai
    Posts
    687
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to get column name&Cell value using datatatabl

    ColumnName = DataTable.GetSheet("Global").GetParameter(1).Name
    With Best Regards
    Yuva

  7. #7
    Member
    Join Date
    Apr 2007
    Location
    AP,India
    Posts
    63
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to get column name&Cell value using datatatabl

    Try this code.


    DataTable.ImportSheet "C:\Documents and Settings\Rajesh\Desktop\input.xls" ,1 ,"Global"
    Set mysheet=datatable.GetSheet("Global")
    mysheet.setcurrentrow(row_no)
    h=mysheet.Getparameter("column_name").value
    msgbox h

    or

    mysheet=DataTable.GetSheet("Global")
    Val=mysheet.GetParameter("pswd").ValueByRow(3)
    Msgbox val

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Search Engine Optimisation provided by DragonByte SEO v2.0.36 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 9.38%
vBulletin Optimisation provided by vB Optimise v2.6.4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.2.8 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominate (Lite) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 08:00 AM.

Copyright BetaSoft Inc.