Subject | [IBO] Re: TIB_lookupcombo doesnt appear in the grid? |
---|---|
Author | james_027 |
Post date | 2003-06-17T07:42:14Z |
below is the new source code that I have done as you have instructed
me ... it still doesn't work .... =_(
Hope youre having enough patience with me ... do have any other idea?
what if I send to you the whole file?
Does Jason knows about this one?
my stand alone IB_lookup
-------------------------------
object IB_LookupCombo1: TIB_LookupCombo
Left = 136
Top = 16
Width = 121
Height = 21
DataSource = ds_items
TabOrder = 4
DisplayField = '"Name"'
ShowButton = True
end
my IB_grid with embeded IB_lookupcombo
----------------------------------------------------
object IB_Grid1: TIB_Grid
Left = 0
Top = 41
Width = 589
Height = 207
CustomGlyphsSupplied = []
DataSource = ds_ingredients
Align = alClient
TabOrder = 2
TitleAlignment = gtaCenter
object IB_LookupCombo2: TIB_LookupCombo
Left = 136
Top = 16
Width = 121
Height = 21
DataSource = ds_items
Visible = False
TabOrder = 0
DisplayField = '"items"."Name"'
ShowButton = True
end
end
my parent table
------------------
object ingredients: TIB_Query
ColumnAttributes.Strings = (
'"asdf"=COMPUTED'
'"Unit"=NOCASE')
DatabaseName = 'D:\Works\KSK\database\ACCTDB.GDB'
FieldsVisible.Strings = (
'"IngredientsID"=FALSE'
'"IngredientsName"=TRUE'
'"asdf"=TRUE')
IB_Connection = Form_main.IB_Connection1
SQL.Strings = (
'select "ingredients"."ItemsID", "ingredients"."IngredientsID"
, "' +
'ingredients"."Qty", "ingredients"."Unit",'
' (select "items"."Name" from "items" where "items".ID
= "ingr' +
'edients"."IngredientsID") as "asdf"'
'from "ingredients" '
'')
ColorScheme = True
DefaultValues.Strings = (
'"Qty"=0')
DeleteSQL.Strings = (
'DELETE FROM "ingredients"'
'WHERE'
' "IngredientsID" = :"OLD_IngredientsID" AND'
' "ItemsID" = :"OLD_ItemsID"')
EditSQL.Strings = (
'UPDATE "ingredients" SET'
' "IngredientsID" = :"IngredientsID", /*PK*/'
' "ItemsID" = :"ItemsID", /*PK*/'
' "Qty" = :"Qty",'
' "Unit" = :"Unit"'
'WHERE'
' "IngredientsID" = :"OLD_IngredientsID" AND'
' "ItemsID" = :"OLD_ItemsID"')
InsertSQL.Strings = (
'INSERT INTO "ingredients"('
' "IngredientsID", /*PK*/'
' "ItemsID", /*PK*/'
' "Qty",'
' "Unit")'
'VALUES ('
' :"IngredientsID",'
' :"ItemsID",'
' :"Qty",'
' :"Unit")')
KeyLinks.Strings = (
'"ItemsID"'
'"IngredientsID"')
MasterSource = ds_stocks
MasterLinks.Strings = (
'"ingredients"."ItemsID" = "items".ID')
MasterSearchFlags = [msfOpenMasterOnOpen,
msfSearchAppliesToMasterOnly]
BufferSynchroFlags = []
FetchWholeRows = True
Left = 736
Top = 8
ParamValues = (
'"MLNK_ItemsID""_0"=0')
end
my lookup table
-------------------
object items: TIB_Query
DatabaseName = 'D:\Works\KSK\database\ACCTDB.GDB'
IB_Connection = Form_main.IB_Connection1
SQL.Strings = (
'select "items"."ID", "items"."Name", "items"."Unit2"'
'from "items"')
ColorScheme = False
KeyLinks.Strings = (
'"items".ID = "ingredients"."IngredientsID"')
KeyLinksAutoDefine = False
KeyDescLinks.Strings = (
'"items"."Name" = "asdf"')
KeySource = ds_ingredients
MasterSearchFlags = [msfOpenMasterOnOpen,
msfSearchAppliesToMasterOnly]
OrderingItemNo = 2
OrderingItems.Strings = (
'ID=ID;ID DESC'
'"Name"="Name";"Name" DESC')
OrderingLinks.Strings = (
'ID=ITEM=1'
'"Name"=ITEM=2')
SearchingLinks.Strings = (
'"Name"="Name"')
BufferSynchroFlags = []
FetchWholeRows = True
Left = 736
Top = 104
end
me ... it still doesn't work .... =_(
Hope youre having enough patience with me ... do have any other idea?
what if I send to you the whole file?
Does Jason knows about this one?
my stand alone IB_lookup
-------------------------------
object IB_LookupCombo1: TIB_LookupCombo
Left = 136
Top = 16
Width = 121
Height = 21
DataSource = ds_items
TabOrder = 4
DisplayField = '"Name"'
ShowButton = True
end
my IB_grid with embeded IB_lookupcombo
----------------------------------------------------
object IB_Grid1: TIB_Grid
Left = 0
Top = 41
Width = 589
Height = 207
CustomGlyphsSupplied = []
DataSource = ds_ingredients
Align = alClient
TabOrder = 2
TitleAlignment = gtaCenter
object IB_LookupCombo2: TIB_LookupCombo
Left = 136
Top = 16
Width = 121
Height = 21
DataSource = ds_items
Visible = False
TabOrder = 0
DisplayField = '"items"."Name"'
ShowButton = True
end
end
my parent table
------------------
object ingredients: TIB_Query
ColumnAttributes.Strings = (
'"asdf"=COMPUTED'
'"Unit"=NOCASE')
DatabaseName = 'D:\Works\KSK\database\ACCTDB.GDB'
FieldsVisible.Strings = (
'"IngredientsID"=FALSE'
'"IngredientsName"=TRUE'
'"asdf"=TRUE')
IB_Connection = Form_main.IB_Connection1
SQL.Strings = (
'select "ingredients"."ItemsID", "ingredients"."IngredientsID"
, "' +
'ingredients"."Qty", "ingredients"."Unit",'
' (select "items"."Name" from "items" where "items".ID
= "ingr' +
'edients"."IngredientsID") as "asdf"'
'from "ingredients" '
'')
ColorScheme = True
DefaultValues.Strings = (
'"Qty"=0')
DeleteSQL.Strings = (
'DELETE FROM "ingredients"'
'WHERE'
' "IngredientsID" = :"OLD_IngredientsID" AND'
' "ItemsID" = :"OLD_ItemsID"')
EditSQL.Strings = (
'UPDATE "ingredients" SET'
' "IngredientsID" = :"IngredientsID", /*PK*/'
' "ItemsID" = :"ItemsID", /*PK*/'
' "Qty" = :"Qty",'
' "Unit" = :"Unit"'
'WHERE'
' "IngredientsID" = :"OLD_IngredientsID" AND'
' "ItemsID" = :"OLD_ItemsID"')
InsertSQL.Strings = (
'INSERT INTO "ingredients"('
' "IngredientsID", /*PK*/'
' "ItemsID", /*PK*/'
' "Qty",'
' "Unit")'
'VALUES ('
' :"IngredientsID",'
' :"ItemsID",'
' :"Qty",'
' :"Unit")')
KeyLinks.Strings = (
'"ItemsID"'
'"IngredientsID"')
MasterSource = ds_stocks
MasterLinks.Strings = (
'"ingredients"."ItemsID" = "items".ID')
MasterSearchFlags = [msfOpenMasterOnOpen,
msfSearchAppliesToMasterOnly]
BufferSynchroFlags = []
FetchWholeRows = True
Left = 736
Top = 8
ParamValues = (
'"MLNK_ItemsID""_0"=0')
end
my lookup table
-------------------
object items: TIB_Query
DatabaseName = 'D:\Works\KSK\database\ACCTDB.GDB'
IB_Connection = Form_main.IB_Connection1
SQL.Strings = (
'select "items"."ID", "items"."Name", "items"."Unit2"'
'from "items"')
ColorScheme = False
KeyLinks.Strings = (
'"items".ID = "ingredients"."IngredientsID"')
KeyLinksAutoDefine = False
KeyDescLinks.Strings = (
'"items"."Name" = "asdf"')
KeySource = ds_ingredients
MasterSearchFlags = [msfOpenMasterOnOpen,
msfSearchAppliesToMasterOnly]
OrderingItemNo = 2
OrderingItems.Strings = (
'ID=ID;ID DESC'
'"Name"="Name";"Name" DESC')
OrderingLinks.Strings = (
'ID=ITEM=1'
'"Name"=ITEM=2')
SearchingLinks.Strings = (
'"Name"="Name"')
BufferSynchroFlags = []
FetchWholeRows = True
Left = 736
Top = 104
end