The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
|
|
Lookup Control Trouble
Posted: 02 Oct 07 10:00 AM
|
I have a field on the ticket table that I am using to store the ID of a row from a standalone table. The Lookup control I have added to the ticketdetails form does the lookup correctly. However, the dialog returns the following into the lookup control: "Sage.SalesLogix.Entities.ProductList"
I am not sure what I have missed. Any help would be greatly appreciated. |
|
|
|
Re: Lookup Control Trouble
Posted: 02 Oct 07 10:54 AM
|
Chnage your LookupBindingMode from Object to String.
However, there is a better way IMO. This is where things are different than what you are used to in the LAN client with regards to lookups. The best way to use a lookup is to create a relationship on your entity so you have an object property for the entity you'll be looking up. Then use that object property to bind to the lookup, instead of the string ID property (which I usually hide, or not include on the entity so I don't have both the string ID property as well as the object property from the relationship).
Make sense?
-Ryan |
|
|
|
Re: Lookup Control Trouble
Posted: 02 Oct 07 11:47 AM
|
This is the approach I took. I created a relationship from the Ticket to the new entity, then bound the lookup to the new property object. The Lookup Binding Mode is set to Object and the Lookup Entity Name is set to the new entity. I have also tried creating the relationship from the new entity, but both give the same results, "Sage.SalesLogix.Entities.ProductList". |
|
|
|
Re: Lookup Control Trouble
Posted: 02 Oct 07 11:54 AM
|
Ah, are you saying that "Sage.SalesLogix.Entities.ProductList" is what shows in the Lookup when an item is selected?
If that is the case then that means you have not yet set a string expression for the ProductList entity. Open the ProductList entity, go to the last tab and enter a string expression for it. Whatever you want to appear in things like lookups is what you'll put here. For example, if there is a property called ListName on the entity and you want that to show in the Lookup, enter the followign into the string expression:
${ListName}
You'll basically put ${PropertyName} there where PropertyName is the name of a property on the entity (case-sensitive). Make sense? |
|
|
| |
|
Re: Lookup Control Trouble
Posted: 21 Dec 07 3:19 PM
|
Ifinally figured out how to add a lookup thank you so much to this message board.
My question now is if I want to show 2 fields from the look up table like the ${Name} and ${Descripion} fields. I can show the Description field but if I also want to show Name. Do i have to make another relationship entity or is there some other trick . |
|
|
| |
| |
|