Jump to content

Why is a window not activated by a partial title?


Zawarujqa
 Share

Recommended Posts

A C# / .Net 5.0 console project.

using AutoIt;
using System;
using static AutoIt.AutoItX;

AutoItSetOption("WinTitleMatchMode", -2);

Console.WriteLine("Window activating...");


Console.WriteLine(
    "by partial title: " +
    WinActivate("OneNote")
);

Console.WriteLine(
    "by full title: " +
    WinActivate("title - OneNote")
);

Console.WriteLine(
    "by handle: " +
    WinActivate(new IntPtr(0x0000000000250D90))
);

The output:

Window activating...
by partial title: 0
by full title: 1
by handle: 1

Why the partial title activation doesn't work?

Link to comment
Share on other sites

  • Developers

Did you check whether there a more windows that could be valid for the partial window title?

2 hours ago, Zawarujqa said:

If the AutoIt project is not dead, then it is definitely sluggishly maintained.

..and your point being?:

  • show how thankful you are?
  • Trying to be a smart-ass?
  • anything in between those 2 categories?

Let us know when you have any comments that contribute like what you are currently missing. ;) 

Jos

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

15 minutes ago, Jos said:

Did you check whether there a more windows that could be valid for the partial window title?

Just one window.

Apparently, I'll have to use p/invoke or look for nuget packages for UI automation. I have a feeling that migration from AutoIt to .NET of my 2013 project will take a very loooong time… Although why am I surprised? After all, I'm using free tools. Furthermore, from 2018.

Link to comment
Share on other sites

Link to comment
Share on other sites

14 hours ago, Nine said:

With the attitude you just showed, I highly doubt someone will run to help you out.  Good luck though.

Well, thank you for another pointless answer.

It is very sad that people with the Developers & MVPs statuses are of no use. This is the price we pay for using free closed-source tools developed by unpaid enthusiasts.

Link to comment
Share on other sites

  • Developers
19 minutes ago, Zawarujqa said:

This is the price we pay for using free closed-source tools developed by unpaid enthusiasts.

Yeap.

Think we are done here.

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Jos locked this topic
Guest
This topic is now closed to further replies.
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...