SPONSORS:






User Tag List

Results 1 to 9 of 9
  1. #1
    Member
    Join Date
    Mar 2002
    Location
    India
    Posts
    63
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Pl. help, How to pass data from .XLS file in Silk Test

    Hi! All

    I have just started automated testing

    Pl. help, How to pass data from .XLS(MsExcel) file in Silk Test?
    -amit


    ------------------

  2. #2
    Senior Member
    Join Date
    Oct 1999
    Location
    san jose, CA
    Posts
    172
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Pl. help, How to pass data from .XLS file in Silk Test

    You will get quicker answer if you post this question under Silk Topic, but you can use

    Declare :
    HFILE hFile
    STRING sLine
    Open the file to read:
    hFile = FileOpen ("mydata.xls", FM_READ)
    process the lines
    while (FileReadLine (hFile, sLine))
    close the file:
    FileClose (hFile)


    ------------------

  3. #3
    Super Member
    Join Date
    Jul 2001
    Location
    Earth
    Posts
    1,882
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Pl. help, How to pass data from .XLS file in Silk Test

    Well the above code will get you a lot of intersting characters, but you probably want to actually be able to read in what is in the file....

    Check out: http://www.ameliortech.com/stuff/too...Test_Excel.zip

    For an article on how to access .XLS (Excel) using ODBC functions in SilkTest.

    ------------------
    James Soderborg
    http://www.ameliortech.com
    jamesso@ameliortech.com

  4. #4
    Junior Member
    Join Date
    Nov 2001
    Location
    Pune
    Posts
    2
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Pl. help, How to pass data from .XLS file in Silk Test

    Thanx!!!

    will check it out and get back to you

    -amit


    ------------------

  5. #5
    Senior Member
    Join Date
    Oct 1999
    Location
    san jose, CA
    Posts
    172
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Pl. help, How to pass data from .XLS file in Silk Test

    Thanks James!! It looks great ..I can use it myself....I knew my way wasn't the right approach but it did what I intended to do for sometime...

    Thanks
    Imad


    ------------------

  6. #6
    Member
    Join Date
    Mar 2002
    Location
    India
    Posts
    63
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Pl. help, How to pass data from .XLS file in Silk Test

    Thanx, James

    I just tried it and it works fine, really a good example,




    ------------------

  7. #7
    Member
    Join Date
    Mar 2002
    Location
    India
    Posts
    63
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Pl. help, How to pass data from .XLS file in Silk Test

    Thanx, Imad,
    it works fine,

    I think What u have suggested is better with text files,
    but then how to identify different columns in a row?
    so that we can use it when Xls file is not available,

    -amit

    <BLOCKQUOTE><font size="1" face="Verdana, Arial, Helvetica">quote:</font><HR>Originally posted by imad:
    You will get quicker answer if you post this question under Silk Topic, but you can use

    Declare :
    HFILE hFile
    STRING sLine
    Open the file to read:
    hFile = FileOpen ("mydata.xls", FM_READ)
    process the lines
    while (FileReadLine (hFile, sLine))
    close the file:
    FileClose (hFile)


    <HR></BLOCKQUOTE>



    ------------------

  8. #8
    Super Member
    Join Date
    Jul 2001
    Location
    Earth
    Posts
    1,882
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Pl. help, How to pass data from .XLS file in Silk Test

    When an xls file isn't avaialble, use a comma delimited file (or some other delimeter is fine too). Using the file routine above will get you the rows. Use GetField () function to get at the columns.

    ------------------
    James Soderborg
    http://www.ameliortech.com
    jamesso@ameliortech.com

  9. #9
    Senior Member
    Join Date
    Nov 2000
    Location
    Bloomington, IL
    Posts
    142
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Pl. help, How to pass data from .XLS file in Silk Test

    I have found that working with Excel files can introduce to many variables (based on who entered the data) so I convert all of me input file to an ODBC database for standardization.

    MikeF

    ------------------

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

vBulletin Optimisation provided by vB Optimise v2.6.0 Beta 4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.0.9 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Questions / Answers Form provided by vBAnswers (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominatevBulletin 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 02:02 PM.

Copyright BetaSoft Inc.