Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using Keyboard.pressing(VirtualKeyShort.ALT) not working #320

Open
rahulkate-bit opened this issue Mar 6, 2020 · 4 comments
Open

Using Keyboard.pressing(VirtualKeyShort.ALT) not working #320

rahulkate-bit opened this issue Mar 6, 2020 · 4 comments

Comments

@rahulkate-bit
Copy link

rahulkate-bit commented Mar 6, 2020

I am trying to do something like this on an application

using(Keyboard.Pressing(VirtuaalKeyShort.ALT))
{
     Keyboard.Type("y");
}

but it does not seem to be working.

But this seems working

using(Keyboard.Pressing(VirtuaalKeyShort.CONTROL))
 {
        Keyboard.Type("y");
}

Flaui 3.0.0 nuget package for c#

Update. It works with Notepad. But not working in a particular software that I am trying to automate.

Any help would be much appreciated.
Thanks

@Roemer
Copy link
Member

Roemer commented Mar 13, 2020

Can you try Keyboard.Type(VirtualKeyShort.KEY_Y)? Also try the key z in case there is some region settings problem.

@rahulkate-bit
Copy link
Author

rahulkate-bit commented Mar 16, 2020

Figured out that for this app this works

Keyboard.Type(VirtuaalKeyShort.CONTROL);
Keyboard.Type(VirtuaalKeyShort.KEY_Y);

but this does not

using(Keyboard.Pressing(VirtuaalKeyShort.CONTROL))
{
     Keyboard.Type(VirtuaalKeyShort.KEY_Y);
}
or 
 Keyboard.TypeSimultaneously(VirtuaalKeyShort.CONTROL, VirtuaalKeyShort.KEY_Y);

Also now this application is not accepting Alt + P combination at a certain stage via flaui.
Though if I type from my keyboard there it works like a charm,

Actually in this application it takes on full screen by default, also I can just get the parent window in inspect tool I don't get any child control in the inspect tool. Not even sure what this app is made from.

Any thoughts?

@Roemer
Copy link
Member

Roemer commented Apr 17, 2020

Probably related to #295

@Benjamin-Grimm
Copy link

Is there any update or workaround for this issue?
We had some partial success with using SendKeys instead, but this only worked when the tests ran locally in our Azure pipeline this did not work either.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants