SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 4 of 4
  1. #1
    Member
    Join Date
    May 2004
    Location
    Boston, MA
    Posts
    79
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Problem selecting/checking items in a SwfCheckedListBox

    Wondering if anyone has encountered a similar issue working with a .Net winforms application.

    Environment:
    SilkTest 7.5
    .Net Extension loaded.
    use "msw32.inc" declared in .inc file as well.

    Declaration:
    </font><blockquote><font size="1" face="Verdana, Arial, Helvetica">code:</font><hr /><pre style="font-size:x-small; font-family: monospace;">
    [-] window SwfChildWin Reports
    [-] multitag &quot;Reports&quot;
    [ ] &quot;$frmReportSelection&quot;
    [ ] parent ReportsApp
    [-] SwfGroupBox ReportsGroupBox
    [-] multitag &quot;Reports&quot;
    [ ] &quot;$groupBox1&quot;
    [-] SwfCheckedListBox ListReports
    [ ] tag &quot;$listReports&quot;

    </pre><hr /></blockquote><font size="2" face="Verdana, Arial, Helvetica">The method I'm using to try to select an item from the list:

    </font><blockquote><font size="1" face="Verdana, Arial, Helvetica">code:</font><hr /><pre style="font-size:x-small; font-family: monospace;">[-] testcase Select_PortfolioReview () appstate none
    [ ] Reports.SetActive ()
    [ ] Reports.ReportsGroupBox.ListReports.DoubleSelect (&quot;Portfolio Review&quot</pre><hr /></blockquote><font size="2" face="Verdana, Arial, Helvetica">The error I get back from Silk is:
    [ ] *** Error: Window '[SwfCheckedListBox]$listReports' is not active
    [ ] Occurred in DoubleSelect

    Things I have tried to work around this problem:

    1) I've tested to see if the control is active, it's not.
    </font><blockquote><font size="1" face="Verdana, Arial, Helvetica">code:</font><hr /><pre style="font-size:x-small; font-family: monospace;"> [ ] BOOLEAN bActive = Reports.ReportsGroupBox.ListReports.IsActive ()
    [ ] PRINT (bActive)

    Returns &quot;FALSE&quot;</pre><hr /></blockquote><font size="2" face="Verdana, Arial, Helvetica">I've tried to set it active and/or give focus to the control.

    Reports.ReportsGroupBox.ListReports.SetActive ()

    Silk won't let me perform this.

    Reports.ReportsGroupBox.ListReports.SetFocus () works, but can still not do a DoubleSelect () on it without the 'is not active' error.

    2) I've tried to use a SendMessage function to the control from my script
    </font><blockquote><font size="1" face="Verdana, Arial, Helvetica">code:</font><hr /><pre style="font-size:x-small; font-family: monospace;"> [-] SwfCheckedListBox ListReports
    [ ] tag &quot;$listReports&quot;
    //sReport is the report name to select from the CheckedListBox
    [-] SelectReport (STRING sReport)
    [ ] integer iHandle
    [ ] long lReturn
    [ ] iHandle = this.GetHandle ()
    [ ] SendMessage (iHandle, LBN_DBLCLK,0,sReport)</pre><hr /></blockquote><font size="2" face="Verdana, Arial, Helvetica">Called from script via:
    Reports.ReportsGroupBox.ListReports.SelectReport (sReport)

    This did not work.

    I was able to perform the following actions on the SwfCheckedListBox.
    Reports.ReportsGroupBox.ListReports.GetContents ()

    That pulled everything out to the list, so I'm not getting why I can't perform a DoubleSelect on the object.

    I logged a ticket with Segue support and, unfortunately they could not offer up a resolution.

    Anyone else encounter these types of problems with nested controls within a SwfGroupBox before?

    Any tips/tricks would be appreciated.

    Thanks.

    Drew
    Drew

    Actual quote from an email I received from a product manager:
    "I want to tell all our customers to go to it (site) on Monday next week. I especially want to make sure the forums work right. Can you test every feature you can find?"

  2. #2
    Junior Member
    Join Date
    Aug 2005
    Location
    shanghai
    Posts
    9
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Problem selecting/checking items in a SwfCheckedListBox

    Hi,all
    Does anybody meet the same problem?
    or does andy feedback about this?

    Thanks in advance.

  3. #3
    Advanced Member
    Join Date
    Oct 1999
    Location
    Chicago, IL
    Posts
    652
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Problem selecting/checking items in a SwfCheck

    I have not used the .Net functionality too much. But things I would try... Do all methods against this control exhibit the same behavior, such as Select(), GetContents(), TypeKeys()?

    As a test, try the following just to see if it works. Although I don't feel it should be your permanent solution...

    <font class="small">Code:</font><hr /><pre>
    [-] testcase Select_PortfolioReview () appstate none
    [ ] Reports.SetActive ()
    [ ] Agent.SetOption (OPT_VERIFY_ACTIVE, FALSE)
    [ ] Reports.ReportsGroupBox.ListReports.DoubleSelect ("Portfolio Review")
    [ ] Agent.SetOption (OPT_VERIFY_ACTIVE, TRUE)
    </pre><hr />

  4. #4
    Junior Member
    Join Date
    Aug 2005
    Location
    shanghai
    Posts
    9
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Problem selecting/checking items in a SwfCheck

    Hi, Brian

    I have checked in the help doc,
    for the method DoubleSelect, it always requires active window and enabled window.

    Why you suggest to set FALSE?
    ----Agent.SetOption (OPT_VERIFY_ACTIVE, FALSE)

    thanks

 

 

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 10.71%
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 09:46 PM.

Copyright BetaSoft Inc.