Search found 6698 matches

by Marcus Tettmar
Wed Jul 31, 2019 11:04 pm
Forum: General Discussion
Topic: Connection to SAP
Replies: 1
Views: 773

Re: Connection to SAP

If the code runs in a regular .vbs file outside of SAP then yes. But if the code accesses properties only exposed by the container - SAP - then probably not.
by Marcus Tettmar
Fri Jul 12, 2019 6:38 am
Forum: Technical / Scripting
Topic: Hello, question
Replies: 1
Views: 127

Re: Hello, question

Yes, press left and right mouse buttons together to copy content of cursor monitor to clipboard.
by Marcus Tettmar
Fri Jul 12, 2019 6:37 am
Forum: Technical / Scripting
Topic: How to change parameter in a Macro using the Dialog
Replies: 2
Views: 185

Re: How to change parameter in a Macro using the Dialog

Look at the topic Command Line Options in the help file. This shows how you can pass parameters as variables into macros when you run them.
by Marcus Tettmar
Fri Jul 12, 2019 6:36 am
Forum: Technical / Scripting
Topic: FindImagePos then LClick (works great), but if statement to not click again
Replies: 1
Views: 109

Re: FindImagePos then LClick (works great), but if statement to not click again

Try changing the matching method from CCOEFF to EXACT so that it does an EXACT match. At the moment it sounds like it is seeing the two as the same thing - CCOEFF is statistical pattern matching and is designed to be tolerant. The purple version is similar, so it sees it as the same thing. That is h...
by Marcus Tettmar
Mon Jul 01, 2019 2:39 pm
Forum: Technical / Scripting
Topic: Return partial variables within string
Replies: 5
Views: 367

Re: Return partial variables within string

PepsiHog's solution still works. It doesn't care what the separator is.
by Marcus Tettmar
Mon Jul 01, 2019 2:37 pm
Forum: Technical / Scripting
Topic: Copy last three characters of a variable to a new variable
Replies: 5
Views: 329

Re: Copy last three characters of a variable to a new variable

You probably have previous programming experience which will be a benefit for logic but a deficit for syntax. You need to study posted scripts and get a feel for available commands and Macro Scheduler syntax which does not allow multiple functions on the same line. CGooley's syntax is correct - it ...
by Marcus Tettmar
Mon Jul 01, 2019 2:35 pm
Forum: Technical / Scripting
Topic: Copy last three characters of a variable to a new variable
Replies: 5
Views: 329

Re: Copy last three characters of a variable to a new variable

Here is how I am currently trying to do this: GetClipBoard>filename Let>filenamelength={length(%filename%)} Let>count=filenamelength-3 Let>at={Pos(" ",%filename%)} Let>branch={copy(%filename%,count,%at%-1)} message>branch Branch should return the last 3 characters, but only does this if I specify m...
by Marcus Tettmar
Mon Jul 01, 2019 12:10 pm
Forum: Technical / Scripting
Topic: Executing or opening an invalid file path
Replies: 5
Views: 295

Re: Executing or opening an invalid file path

I would just check that the file exists before doing anything:

Code: Select all

SRT>Open_Sub
  IfFileExists>file
    ExecuteFile>file
  Else
    MessageBox>Please enter a valid file first!
  Endif
END>Open_Sub
by Marcus Tettmar
Mon Jun 24, 2019 11:44 am
Forum: Technical / Scripting
Topic: vbs
Replies: 10
Views: 441

Re: vbs

Your code should be: VBStart Option Explicit Sub MoveFolder(Source,Dest) Dim fso Set fso = CreateObject("Scripting.FileSystemObject") fso.MoveFolder Source, Dest End Sub VBEND //C:\Users\Felix The Cat\Desktop\Move this folder //C:\Users\Felix The Cat\Desktop\Move here let>Source=%Desktop_Dir%\Move t...
by Marcus Tettmar
Mon Jun 24, 2019 11:42 am
Forum: Beginners
Topic: Image Recognition faster
Replies: 1
Views: 160

Re: Image Recognition faster

About the only way you can make it faster (other than use more powerful hardware) is to make the search area (the haystack) smaller. Using SCREEN will search the entire desktop area. If you have multiple large monitors at a very high resolution then clearly that is going to take a lot longer than se...
by Marcus Tettmar
Tue Jun 18, 2019 12:10 pm
Forum: Scripts and Tips
Topic: Find or Wait for Object then Click other object
Replies: 5
Views: 864

Re: Find or Wait for Object then Click other object

Can you explain what you mean?
by Marcus Tettmar
Tue Jun 18, 2019 12:10 pm
Forum: The Water Cooler
Topic: uiClick
Replies: 2
Views: 1599

Re: uiClick

No idea, but uiClick performs the default action. What that is and how the software responds is down to the guys or gals who developed it. And to us it's a black box. So frankly I have no idea. That's automation for you. You try stuff and see what works. We can't usually see the code and therefore c...
by Marcus Tettmar
Tue Jun 18, 2019 12:08 pm
Forum: Beginners
Topic: Manual unlock after enabling AutoLogon
Replies: 5
Views: 626

Re: Manual unlock after enabling AutoLogon

I think it's expecting a local account. Instead of the domain try entering the PC name.
by Marcus Tettmar
Wed May 29, 2019 5:38 pm
Forum: Technical / Scripting
Topic: FindImagePos and return_offset
Replies: 3
Views: 317

Re: FindImagePos and return_offset

JPG aren't supported *AT ALL* in this function. The help file says: needle_bitmap should be a fully qualified path to a bitmap or png file (see MatchAlgorithm type below for supported image types). MatchAlgorithm goes on to say that EXACT *only* works with BMP files while CCOEFF works with PNG or BM...
by Marcus Tettmar
Wed May 29, 2019 5:36 pm
Forum: Beginners
Topic: Create a simple dialog with memo box
Replies: 2
Views: 209

Re: Create a simple dialog with memo box

Just do exactly that. Create a custom dialog. Put only a memo box on it.

Prior to showing the dialog load the file into a variable using ReadFile and then set the text of the memo with this variable using SetDialogProperty.