Home > Net >  Pray for Delphi program controls in the text of the code (text) access to a third party program cont
Pray for Delphi program controls in the text of the code (text) access to a third party program cont

Time:10-13

I have here a software is developed with Delphi, there is a window to enter some text box input data members, now I want to do a small program to automatically input text box of the data, the text frame's data can handle by looking for control of the text, but the data according to the member input window at the bottom of the control display content to determine what data input, the data is written to the database successfully, check some information on the net, can handle to access control, but can't extract text control, because I am a novice, want to write a piece of code in the description to help achieve I want, also can add comments that is best,
Below is I want to control the development of the Delphi program interface

I want to read the "card number is empty, can't write CARDS" this area displays the text, I used a similar to the following method can take the text of the status bar to the text document, but take less than the interface card number is empty, can't write a card "the words,

Part of the code
GetWindowThreadProcessId (hTargetWindow lProcessID)
HProcess=OpenProcess (PROCESS_ALL_ACCESS, False, lProcessID)
If hProcess=0 Then the Exit Sub
LpBuffer=VirtualAllocEx (ByVal hProcess, ByVal 0 & amp; Len (s), MEM_COMMIT, PAGE_READWRITE)
If lpBuffer=0 Then the Exit Sub
LPartIndex=1
Call SendMessage (hStatusBar, SB_GETTEXT lPartIndex, ByVal lpBuffer)
Call ReadProcessMemory (ByVal hProcess, ByVal lpBuffer, ByVal s, Len (s), ByVal 0)
VirtualFreeEx hProcess, ByVal lpBuffer, 0, MEM_DECOMMIT
The Debug. Print "status bar". LPartIndex + 1; "In the word is:"; S
This control is shown in SPY as part of the TdxStatusBar

Ask everyone to use any way to read text written by Delphi TdxStatusBar controls?

CodePudding user response:

You see this resource can help to you
http://download.csdn.net/detail/mjp1234airen4385/1550580

CodePudding user response:

Thank mjp1234airen4385, you don't seem to be against the resources of third party programs

CodePudding user response:

Your problem solved, convenient to share the method

CodePudding user response:

Problem solving of the building Lord, I am now remote injected, but don't know how to get the static text object, convenient method under the share?

CodePudding user response:

Others used the Delphi!!
I also in use, ha ha!
  •  Tags:  
  • C#
  • Related