Print Page | Close Window

Browse Model.EntityRelations

Printed From: IdeaBlade
Category: DevForce
Forum Name: DevForce Classic
Forum Discription: For .NET 2.0
URL: http://www.ideablade.com/forum/forum_posts.asp?TID=653
Printed Date: 03-Apr-2025 at 11:49pm


Topic: Browse Model.EntityRelations
Posted By: jcdk
Subject: Browse Model.EntityRelations
Date Posted: 11-Jan-2008 at 7:38am
Hi
 
is there a way to get a browseable list of entity relations in my model? I am aware of the Model.EntityRelations, but it doesn't really fit my need.
 
What I want to do is a sort of dynamic search tool that takes one business object as its first input and then suggests all the tables that have a direct relation to the selected table. To do that in an effective manner I need access to a browseable list of the relations of the first business object.
 
Best regards
Jesper Carstensen 



Replies:
Posted By: davidklitzke
Date Posted: 11-Jan-2008 at 9:51am
Model.Entity.Relations does have all of the information you need.  It is just that the information is presented in a way that is not easy for you to
build the browseable list.  However, it can be done.
 
I suggest that you create a utility or method that will do what you want it to do.  Get all of the Entity Relations in your application by calling GetEntityRelations() and then step through each of the entity relations to build the browseable list that you want.


Posted By: jcdk
Date Posted: 11-Jan-2008 at 10:55am
Tongue Bingo, just what I needed.
 
Sometimes it's just a matter of finding the right way.
 
Thanks a lot.
 
Regards
Jesper Carstensen



Print Page | Close Window