SPONSORS:






User Tag List

Results 1 to 4 of 4

Thread: new line

  1. #1
    Member
    Join Date
    Aug 2000
    Location
    sanjose
    Posts
    30
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    new line

    Hello.

    I have a question.

    When printing to a results file using Print(...) and LogError(...) how do i create a
    carriage return in the string?

    Example:

    LogError ("FAIL - Unexpected window appeared. The expected 'Edit' window did NOT appear.")

    The above prints:

    FAIL - Unexpected window appeared. The expected 'Edit' window did NOT appear.

    How do i get it to print:

    FAIL - Unexpected window appeared.
    The expected 'Edit' window did NOT appear.

    using only one LogError(...) statement?


    Thanks,
    Nick

    ------------------
    ram
    ram

  2. #2
    Member
    Join Date
    Nov 2000
    Location
    Newport News, VA U.S.
    Posts
    30
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: new line

    I know how to put a carriage return with Print (), but don't know how to do it with LogError ()...

    print (" hello {chr(10)} hello")

  3. #3
    Pal
    Pal is offline
    Apprentice
    Join Date
    Jan 2001
    Location
    Levittown, NY,USA
    Posts
    36
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: new line

    Hi Ksr7777
    Try to use verify statement do...except as:

    [-]do
    [ ]Verify (Browser.ABC.Exists (), TRUE)
    [-]except
    [ ] LogError ("ERROR ****** ")

    It will print log error. I hope it works.

    Thanks
    Pal




  4. #4
    Guest

    Re: new line

    You can use the Printf() function to print strings with new line characters to the results file. I don't know of a way to do it with LogError(). Even if you combine the LogError() and PrintfToString() functions it won't work.

 

 

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 08:58 PM.

Copyright BetaSoft Inc.