Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Select a column of a row in a datawindow

Status
Not open for further replies.

TonCoronel

Programmer
Dec 1, 2003
37
NL
I have a datawindow and it displays company's,projects and some other thnigs
soemthing like this:

Code Company project ....
AAA Bouwvest 12 impressies ....
etc etc etc etc.

If someone clickes on a row in a particulair column it should display the details of the selected Company or project. How can I achieve this? becuase I dont believe there is something like company = dw_1.GetSelectedColumn ore something like that
 
never mind I solved it myself.

I first get the selected row bye the .getrow function and then I get the selected column with the .getselectedcolumn function and combine them in the getitemnumber function. works great
 
Use this:

datawindow::doubleclicked (xpos, ypos, dwo)
{
Code:
string ls_type
string ls_column_name

ls_type = dwo.Type

if ls_type = "column" then
  ls_column_name = dwo.Name 
end if

if ls_type = "text" then
  // only then column headers in DW = column names
  ls_column_name = dwo.Text 
end if
}
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top