DevExpress Grid and SF


Author
Message
Terry Bottorff
Terry Bottorff
Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)
Group: Forum Members
Posts: 448, Visits: 12K
I am using the latest version of DevExpress and SF in VS 2008. I created a BO and just by using a break point I found that it does have data in it. I also created a Custom Business Binding Source and put in the code so it does appear on my toolBox. I dropped the BO and the BBS on my form. I also have placed a DevExpress Grid on my form.

Using the little black arrow on the top right of the grid(forgot what it is called) I did the following steps:

1. Choose Data Source.

2. Add Project Data Source.

3. Choose Object as data type.

4. Found my BOLib, found my BBS and selected it.

5. It immediately created the databindingsource and put the columns that I want in the grid.

6. I looked at the columns and they have the correct field names in them.

7. Because of #5 and #6 I think the grid is set up correctly?????

8. Run project and the grid shows with the column titles but no data.



What am I missing? TIA.

Trent Taylor
Trent Taylor
StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 6.9K
Sounds like you did fine. Have you looked at the Grid sample that comes with SF? It isn't using a DevExpress grid, though I do think that one of the SF DevExpress samples does have a grid in it which might help as well.
Terry Bottorff
Terry Bottorff
Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)
Group: Forum Members
Posts: 448, Visits: 12K
I am having a problem loading the example. All kinds of errors. I will work on that. One thought, I don't have to load data in the BBS do I if I loaded data in the BO?

Also, anyone else got any ideas? TIA.
Terry Bottorff
Terry Bottorff
Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)
Group: Forum Members
Posts: 448, Visits: 12K
When I select the data source for the DevExpress Grid does it matter where I select the data source from:

Project Data Source?

Form List Instance?

Add Project Data Source and Select Object?



Also, is there a way to view the data in the BBS with the visualizer like you can in the BO?



Yuck I am having about as much fun with this as I can stand......Crying
Terry Bottorff
Terry Bottorff
Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)
Group: Forum Members
Posts: 448, Visits: 12K
This is plumb dumb. It can not be this hard. I just created a simple project with a form, BO, and BBS. With a break point I know the BO has data with the visualizer. I add a DevExpress Grid and select the data source which is my BBS. It populates the columns with the correct fields. When I run it I get NO DATA. What property do I need to set?
Peter Jones
Peter Jones
Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)
Group: Forum Members
Posts: 386, Visits: 2.1K
Hi Terry,



I think you need to be looking at this at run-time. Why not add a button to your form and break when its clicked. You can then look at your grid and its data source in 'real-time' to see what the status is. I can only figure that your BO is empty.



Cheers, Peter
Terry Bottorff
Terry Bottorff
Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)
Group: Forum Members
Posts: 448, Visits: 12K
That is exactly what I did. I click the button. Use me.mybo.currentview and use the watch window and the visualizer and I have 311 records. Yet the grid shows absolutely nothing. I'm overlooking something or some switch and I know it but i'll be D...... if I know what it is???? TIA.
Peter Jones
Peter Jones
Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)
Group: Forum Members
Posts: 386, Visits: 2.1K
Hi Thomas,



Yes but the grid is displaying data from the business binding source (bbs) for the bo not the bo itself. Does the bbs' current view contain data?



Cheers, Peter

'
Terry Bottorff
Terry Bottorff
Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)
Group: Forum Members
Posts: 448, Visits: 12K
On my break point I tried this in the Watch Window:

me.myBBS.CurrentView but I could find that.

So I tried me.myBBS.SourceBO.CurrentView and it had Zero(0) Records.



If that is where I should have looked then no wonder the grid has no records. But is that where I should have looked? If so what could I have done wrong in setting up the BBS? Setting up a BBS seems to be so straight forward.



If these are goofy questions I am sorry but I'm a newbie to Strataframe which of course makes me a real newbie to DevExpress.....







Peter Jones
Peter Jones
Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)Advanced StrataFrame User (504 reputation)
Group: Forum Members
Posts: 386, Visits: 2.1K
Hi Terry (sorry about the Thomas),



In the Watch Window you should be able to see:



Me.MyBBS.BusinessObject.CurrentView.

This is the data your grid is using



The first path under BusinessObject should be the name of the BO that populates the BBS. If this as expected?



You can the drill down into the BO (in Me.MyBBS.BusinessObject.YourBOName) itself to see what it says about its data source and all its controls.



Do you use the BO's ParentFormLoading event to populate your BO when the form opens?



Cheers, Peter
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search