SPONSORS:






User Tag List

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

    Copy the Text in TextField

    Hi,
    I want to copy the text in a textfield (This text field isn't editable). I tried with
    TextField.PressKeys ("<Ctrl>")
    TextField.PressKeys ("<Shift>")
    TextField.PressKeys ("<End>")

    TextField.ReleaseKeys ("<Ctrl>")

    TextField.ReleaseKeys ("<Shift>")

    TextField.ReleaseKeys ("<End>")
    TextField.PressKeys("<Ctrl>")
    TextField.TypeKeys ("<C>")
    TextField.ReleaseKeys("<Ctrl>")

    But this didn't help. Can anyone help me out to copy the text(MultiText) of TextField

    Sam.V
    Samatha.V

  2. #2
    Senior Member
    Join Date
    Jun 1999
    Location
    Fremont, CA, USA
    Posts
    355
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Copy the Text in TextField

    Why not TextField.GetMultiText()?



    ------------------
    David Genrich
    david.genrich@e2open.com
    david@linuxpuppy.net

  3. #3
    Junior Member
    Join Date
    Mar 2002
    Posts
    14
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Copy the Text in TextField

    Hi David,
    Thanks for the reply. Well i forgot to mention that i can use MultiText() method. But the probs with is it doesn't get the empty lines in the text. Actually i have empty lines in between the text. So this method doesn't help me. can u suggest me any other way to get those empty lines.I even tried with GetContents(). Even that didn't help me.

    Thanks
    Sam.v


    ------------------
    Samatha.V
    Samatha.V

  4. #4
    Junior Member
    Join Date
    Mar 2002
    Posts
    14
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Copy the Text in TextField

    TextField.PressKeys ("<Ctrl>")
    TextField.PressKeys ("<Shift>")
    TextField.PressKeys ("<End>")
    TextField.ReleaseKeys ("<Ctrl>")
    TextField.ReleaseKeys ("<Shift>")
    TextField.ReleaseKeys ("<End>")
    TextField.PressKeys("<Ctrl>")
    TextField.TypeKeys ("<C>")
    TextField.ReleaseKeys("<Ctrl>")
    TextField.ReleaseKeys ("<C>")
    Samatha.V

  5. #5
    Junior Member
    Join Date
    Mar 2002
    Posts
    14
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Copy the Text in TextField

    Hi All,
    Actually the keys in the above presskeys and release keys are "Ctrl-Shift-End" and Ctrl-C.
    Samatha.V

  6. #6
    Junior Member
    Join Date
    Mar 2002
    Location
    Chennai,Tamil Nadu,India
    Posts
    13
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Copy the Text in TextField

    HI try Following Code

    i hope it will help u if u have enabled activex For ur Application.

    /********************************************
    string s
    int i = 1
    s = Form1.TextBox1.GetProperty("$Text")
    [-] while(GetField(s,chr(13),i) !="")
    [ ] print(GetField(s,chr(13),i))
    [ ] i++

    /******************************************
    With regards,
    Myils


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

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

    Re: Copy the Text in TextField

    Thanks for ur reply, Mylis.

    Well, I was able to copy using 'SendMessage' method.



    ------------------
    Samatha.V
    Samatha.V

  8. #8
    Junior Member
    Join Date
    Apr 2002
    Location
    Boston, MA
    Posts
    11
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Copy the Text in TextField

    What is "send message" method? New to silktest.

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

  9. #9
    Member
    Join Date
    Dec 2001
    Location
    chennai,TN,India
    Posts
    30
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Copy the Text in TextField

    U can try the following
    DoubleClick()
    TypeKeys("<CTRL-C>")
    I think this wud help you...

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

 

 

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 10:39 PM.

Copyright BetaSoft Inc.