18 January 2026:


This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.



Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.

Facing problem with datepicker

sujatasujata Members
edited November -1 in Sahi - Open Source
I have created one script.In this script i have written "_click(_link("12[1]"));" for selecting date from a datepicker.When the script is running,after selecting date,the scripts stops,not showing any error also.Can u send me the solution.
Regards
Sujata

Comments

  • SumitraSumitra Members
    Hi Sujata,

    Can you let me know which frame work are you using to select date from datepicker

    Could you post the example of that datepicker.

    Regards
    Sumitra
  • sujatasujata Members
    They are using Zcoss datebox.
  • SumitraSumitra Members
    Hi Sujata,

    Can you post the script for selecting the date from a datepicker.

    Regards
    Sumitra
  • sujatasujata Members
    I am using "_click(_italic("/.*/[1]"));
    _click(_link("12[1]"));"
  • Hi Sujatha ,

    For Date picker you can use this code

    _setSelected(_select("MonSelect"), "Feb");
    _setSelected(_select("YearSelect"), "1978");
    try
    {
    _click(_link("10"));

    }
    catch(e)
    {
    }
  • sujatasujata Members
    _setSelected(_select("MonSelect"), "Feb");
    Not working.So it is not going to next step.
  • SumitraSumitra Members
    Hi Sujata,

    Kindly check this URL:

    http://www.zkoss.org/zkdemo/input/date_and_time_picker

    The script recorded to select the date for Medium under Format looks like this:

    _click(_italic("/a0-btn/"));
    _click(_cell("14"),_under(_cell("Thu")));

    IF you playback this script you can observe that the date is been selected successfully.

    Hope this helps you to resolve your issue.

    Regards
    Sumitra
  • sujatasujata Members
    Thank u all.It is working fine
  • sujatasujata Members
    Thank u all.It is working fine
This discussion has been closed.