Posted: Wed Mar 24, 2010 9:27 pm Post subject: help sending input to a windows edit control using python
Hi ive tried asking on a python forum but no ones has been able to help me. I am trying to write text into a windows edit control using python. it seems to write to every control i try except the edit box not sure if this is a security measure or not. here is my code any help please.
Code:
import os,sys,subprocess,time
from subprocess import *
from os import *
from ctypes import *
from ctypes.wintypes import *
if not window_handle:
print "[*] cant find window"
# 1 is the control id of the edit box child window
#below line has no effect on the control for some reason??
windll.user32.SetDlgItemTextA(window_handle, 1, "bla")
# 2 is the control id of a button
# this line works ? not sure whats going on
windll.user32.SetDlgItemTextA(window_handle, 2, "bla")
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
Featured Links*
Looking for more Windows Networking info?
Sign up to the WindowsNetworking.com Monthly Newsletter, written by Enterprise Security MVP Deb Shinder, containing news, the hottest tips, Networking links of the month and much more. Subscribe today and don't miss a thing! View a sample newsletter.
Become a WindowsNetworking.com member!
Discuss your Windows Networking issues with thousands of other Windows Newtorking experts. Click here to join!