This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Parameters | |
| # Example | |
| # $user = "admin" | |
| # $pass = "admin" | |
| # $instansname = "dev00000" | |
| # $targettablename = "incident" | |
| # $baselocalpath = "C:\snowapi\" | |
| # $outfilename = "incident.xls" | |
| $user = "admin" | |
| $pass = "admin" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # https://arm-lab.blogspot.com/2021/03/servicenowpowershell.html | |
| # Parameters | |
| $user = "admin" | |
| $pass = "admin" | |
| $instansname = "dev00000" | |
| $SysID = "8180046a2fba601033e449e72799b680" | |
| $BasePath = "C:\" | |
| # Build auth header | |
| $base64AuthInfo = [Convert]::ToBase64String([Text.Encoding]::ASCII.GetBytes(("{0}:{1}" -f $user, $pass))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function SwipeUpToTarget targetimage | |
| //call example: | |
| //get myfunctions.SwipeUpToTarget("[targetimage]") | |
| Repeat until ImageFound(Image: targetimage, WaitFor:1) | |
| SwipeUp | |
| wait 1 | |
| End repeat | |
| return | |
| end SwipeUpToTarget |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Params @ Local | |
| $XLSXFileName = "xxxx.xls/xlsx" | |
| $XLSXFilePath = "C:\" | |
| # Params @ SNOW | |
| $InstanceName = "dev00000" | |
| $User = "admin" | |
| $Pass = "admin" | |
| $ImportTableName = 'u_inport_incident_by_xls/xlsx' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Params @ Local | |
| $CSVFileName = "xxxx.csv" | |
| $CSVFilePath = "C:\" | |
| # Params @ SNOW | |
| $InstanceName = "dev00000" | |
| $User = "admin" | |
| $Pass = "admin" | |
| $ImportTableName = 'u_inport_incident_by_csv' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import cloudshell.helpers.scripts.cloudshell_scripts_helpers as helpers | |
| # How to use this file | |
| # | |
| # from Proc_L1ConnectionController import L1ConnectionController | |
| # L1CC = L1ConnectionController() | |
| # L1CC.ChangeStateOfAllL1Routes("Connect") | |
| class L1ConnectionController: | |
| def __init__(self): | |
| self.reservation_id = helpers.get_reservation_context_details().id | |
| self.session = helpers.get_api_session() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| put the RemoteWorkInterval into defaultRWI | |
| put the MouseDoubleClickDelay into clickTime | |
| set the RemoteWorkInterval to clickTime | |
| MoveTo "[TargetImage]" | |
| click | |
| click | |
| click | |
| set the RemoteWorkInterval to defaultRWI |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| set MyFile to resourcepath("textfile.txt") | |
| repeat with MyLine = each line of file MyFile | |
| typetext MyLine, returnKey | |
| end repeat |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| repeat with CurrentImage = each item of ImageInfo("[collection name]") | |
| Click (Image:CurrentImage.imagepath, WaitFor:5) | |
| end repeat |
NewerOlder