By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,952 Members | 1,619 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,952 IT Pros & Developers. It's quick & easy.

Extract Cells From TStringGrid Control

P: 1
2 applications.
my vb.net(**or c#**) project and external application

the external application is developed by delphi.
i want to extract information from this application (extract cells from the `TStringGrid` control).
image:
http://i.stack.imgur.com/lbtNf.png

extract the `1 2 str str` into my Vb.net project.

To make it more convenient to solve the question this is the download of the `external` application:

http://www.4shared.com/get/GsXJMSGz/Project1.html

this is my code so far:

Declarations:

Expand|Select|Wrap|Line Numbers
  1. <DllImport("user32.dll", SetLastError:=True, CharSet:=CharSet.Auto)> _
  2. Private Shared Function FindWindow( _
  3.  ByVal lpClassName As String, _
  4.  ByVal lpWindowName As String) As IntPtr
  5. End Function
  6. <DllImport("user32.dll", SetLastError:=True, CharSet:=CharSet.Auto)> _
  7. Private Shared Function FindWindowEx(ByVal parentHandle As IntPtr, _
  8.                   ByVal childAfter As IntPtr, _
  9.                   ByVal lclassName As String, _
  10.                   ByVal windowTitle As String) As IntPtr
  11. End Function
  12.  
  13. The Code:
  14.  
  15.         Dim TheMainForm As Integer = FindWindow("TCells", "Cells")
  16.         Dim GV As Integer = FindWindowEx(TheMainForm, 0, "TStringGrid", "")
I'm sure that there is a answer to this question.
It is very important to resolve this question because without it my project will not move forward.
Dec 30 '12 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.