Ask a Question

Unable to click into Date Time Picker

sean_ng
Occasional Contributor

Unable to click into Date Time Picker

i am trying to click into a date time picker but there is very less information for me to do so.

I manage to change the month and year but am unable to click into the date, i don't have any code here to show because i don't even know how to start, i try to use the code that i use to change the month and year but unsuccessful.

 

is there any successful example with code anyone can recommend me to have a look ?

I am totally stuck, please help

2 REPLIES 2
UnderTest
Occasional Contributor

Better to change wDate value, or even to execute JavaScript to set datepicker value, instead of clicks.

https://support.smartbear.com/testcomplete/docs/app-objects/specific-tasks/ios/date-picker/setting-d...

sean_ng
Occasional Contributor

i can't pass in value using the wDate, it seems like the date time picker does not allow value to be change unless using a click.

 

i tried using css selectors but it does not work too


CSSSelector("//*[div[class*=available]:not([class*='off'])\"]").Click();

 

function CSSSelector(CSSSelector)

{

var Page, CSSSelector, arr, res, cnt, i,obj;

Page = Sys.Browser().Page("*");

 

var obj = Page.QuerySelector(CSSSelector)

if (obj != null)

{

return obj;

}

else

{

Log.Error("The element was not found.");

}

}

cancel
Showing results for 
Search instead for 
Did you mean: