Lock Screen (FR)
Perfecto Command
mobile:screen:lock
Purpose
Parameters
Name | Type | Possible Values | Description |
---|---|---|---|
timeout | Integer | Time, in seconds, to lock device (default: 10) |
Return Value
OK - if successful
Exceptions
None
Examples
Copy
Java sample
Map<String, Object> param = new HashMap<>();
param.put("timeout", "3");
driver.executeScript("mobile:screen:lock", param);
Copy
C# sample
Dictionary<String, Object> pars = new Dictionary<String, Object>();
pars.Add("timeout", "3");
driver.ExecuteScript("mobile:screen:lock", pars);