microsoft-ui-automation


IUIAutomationValuePattern SetValue has no effect


I am using MS UIAutomation in C++ to control a third party WPF application. I can read the value of an edit control (IUIAutomationElement objects). When I try to set the value with SetValue (IUIAutomationValuePattern objects) it does not return an error, but does not set the value of the edit control.
The manifest contains , the application is signed and is run from C:\Program Files.
I experienced that some UI Elements do not implement the UI Automation Provider correctly, as a result some patterns do simply not work as expected or even fail (although they are shown available).
To verify that the object is corrupt and not your code you could use the ValuePattern via Inspect.exe. Open Inspect -> select the control -> Action (Toolbar) -> ValuePattern.setValue
As a workaround I would suggest you to use SendKeys. If you need to focus the element first, yourAutomationElement.setFocus() is your friend. If setFocus does not work get the ClickablePoint/BoundingRectangle of the AutomationElement and use user32.dll in order to click the object.

Related Links

Not able to click on an element in UIAutomation as it does not have Invoke property.
Windows UI Automation AutomationEventHandler on Start menu
How to get name / value from custom control like the Inspect tool from Microsoft?
use .net ui automation framework to capture user clicks of links in outlook application
Some 3rd party controls are not always accessable in UI Automation
How to check if a form is fully loaded?
IUIAutomationValuePattern SetValue has no effect
Handling ProgressBar's Value change with UIAutomation
.net UIAutomation simple example in C++
IUIAutomation::RemoveAllEventHandlers hangs
UI Automation - Select object based on multiple Identifiers
Microsoft UI Automation not returning expected ComboBox items

Categories

HOME
automapper
weblogic12c
freeradius
apple-push-notifications
filesize
odata
docker-cloud
azure-mobile-services
capistrano
graphql-js
angular2-template
kurento
timber
bellman-ford
yahoo
phpstorm-2017.1
csrf
vimeo
angular4
multi-step
mpu6050
orange-api
vertica
codefluent
android-permissions
weex
multi-upload
batch-rename
acl
device
opentext
raima
window-managers
spreadsheetgear
android-cardview
ccavenue
code-climate
docx4j
source-insight
argv
riotjs
bean-validation
orchardcms-1.8
des
linq.js
python-sounddevice
raytracing
morphline
asihttprequest
code-push
ipp-protocol
spongycastle
realstudio
rightnow-crm
photoswipe
solr-query-syntax
popen
sesame
java-2d
ndk-build
ioctl
grinder
miniconda
lowercase
postal-code
textscan
google-hangouts
ildasm
adwords-apiv201402
multivariate-testing
windows-messages
mfmessagecomposeview
jomsocial
visual-c++-2005
revmob
quickgraph
pacman
html-frames
web-frameworks
days
ofstream
cmath
2d-vector
gprof
struts2-json-plugin
series-40
motodev-studio
firefly-mv
css-friendly
3des
explicit
self-tracking-entities
getimagesize
oracle-pro-c
wmd-editor
acceleration
webclient.uploaddata

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App