Generic Browse Dialog


Author
Message
Ger Cannoll
Ger Cannoll
Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)
Group: StrataFrame Users
Posts: 430, Visits: 507
I changed to DbType.String but it did not make any difference.

After some additinal testing, the only thing I noticed was that in my SearchFiledItem1,  I had called the Field Sma_Name whereas in the business object it was called SMA_NAME. I changed the SearchFiledItem1 to SMA_NAME and it fixed the problem. It obviously looks for an exact match and is case sensitive. Being used to VFP, Case Sensitivity was never an issue so I'l just have to be a bit more careful in future.

Anyway, I think I am where I wanted to be with this.... able to programatically create and call the BrowseDialog, albit for one field. I need to do some more paramerisation but many thanks again for your very detailed and 'patient' assistance
Greg McGuffey
Greg McGuffey
Strategic Support Team Member (3.3K reputation)
Group: Forum Members
Posts: 2K, Visits: 6.6K
No problem.  I had forgot that dictionaries are by default case sensitive. Sorry I didn't catch that earlier and I'm glad you got it working.
Ger Cannoll
Ger Cannoll
Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)
Group: StrataFrame Users
Posts: 430, Visits: 507
I am having a problem setting a property of the Browse programatically. The default browse window that comes up for the conteants is too small and I want to make it biogger:

In design mode, I can change the height (or where the BottomPanel starts). i.e. where the reulsts are shown. This seems to be in a property called BottomPanelContents , but I dont know how to access this: e.g Heght or starting position

bd.FormLayout.BottomPanelContents ???


Ger Cannoll
Ger Cannoll
Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)
Group: StrataFrame Users
Posts: 430, Visits: 507
Any ideas on this ??
Ivan George Borges
Ivan George Borges
Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)
Group: StrataFrame MVPs
Posts: 1.9K, Visits: 21K
Hi Gerard.

Have you tried dealing with the FormLayout property? Also, don't forget you can give your user the ability to make it any size and save the data to a Registry Key:


Ger Cannoll
Ger Cannoll
Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)
Group: StrataFrame Users
Posts: 430, Visits: 507
Yes I tried to use the FormLayout proerty but could not find a property like Size, or Position . For the formlayout.BottomPanel(or TopPanel) It hust seems to have Compare/Equals...Tostring. I have attached a screenshot.
Attachments
BrowseDialog.Formlayout.png (94 views, 144.00 KB)
Ivan George Borges
Ivan George Borges
Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)
Group: StrataFrame MVPs
Posts: 1.9K, Visits: 21K
Have you tried having a look at a BD resource file (its .resx) and checking how the layout is set?
Ger Cannoll
Ger Cannoll
Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)Advanced StrataFrame User (630 reputation)
Group: StrataFrame Users
Posts: 430, Visits: 507
Where would I find the BD resource file  and what should I be looking for (Dont really know waht a resource file is)
Greg McGuffey
Greg McGuffey
Strategic Support Team Member (3.3K reputation)
Group: Forum Members
Posts: 2K, Visits: 6.6K
When you adjust the form layout there are several things you can do:

- Decide where to put the three key elements of a BD: criteria, results and info panel. You have three places you can put them: top panel, bottom panel or side panel.
- You decide if the user can resize the BD. And you can set the size by simply resizing the formlayout dialog that opens.
- You can initially show the bottom panel or side panel.

I highly recommend that you make a little sample app so you can play around with the settings to see what they do and spark your imagination.  Remember you can look at the designer file to see how to programatically setup the BD.

As to resource files, they usually are under files they are associated with. They contains things like position of a component on the design surface (design time) and icons/images/other resources that are embedded directly in a file. They are an XML file and VS has a UI to manipulate them and/or does it automatically when you move a component on the design surface or set an image on a control and use a local resource.
Ivan George Borges
Ivan George Borges
Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)
Group: StrataFrame MVPs
Posts: 1.9K, Visits: 21K
Hi Gerard.

Did I say resource file?! And by that you didn't understand Designer file? Hehe

Sorry about it, I meant the .Designer.vb file. Do you still have the LookUpControlSample I posted for you? You could use it to play around with as Greg mentioned. You can play with the FormLayout and have a look at the CustomersBrowseDialog.Designer.vb and check the properties that set widths, sizes and so on:

        '
        'CustomersBrowseDialog
        '
        BrowseColumnItem1.ColumnHeaderText = "First Name"
        BrowseColumnItem1.ColumnHeaderWidth = 200
        BrowseColumnItem1.ColumnTextAlignment = System.Windows.Forms.HorizontalAlignment.Left
        BrowseColumnItem1.DefaultSort = System.Windows.Forms.SortOrder.None
        BrowseColumnItem1.FormatString = "{0}"
        BrowseColumnItem1.PopulationType = MicroFour.StrataFrame.UI.ListViewColumnPopulationType.FormattedString
        BrowseColumnItem1.RegExPattern = ""
        BrowseColumnItem1.RegExReplacementValue = ""
        BrowseColumnItem2.ColumnHeaderText = "Last Name"
        BrowseColumnItem2.ColumnHeaderWidth = 200
        BrowseColumnItem2.ColumnTextAlignment = System.Windows.Forms.HorizontalAlignment.Left
        BrowseColumnItem2.DefaultSort = System.Windows.Forms.SortOrder.None
        BrowseColumnItem2.FormatString = "{1}"
        BrowseColumnItem2.PopulationType = MicroFour.StrataFrame.UI.ListViewColumnPopulationType.FormattedString
        BrowseColumnItem2.RegExPattern = ""
        BrowseColumnItem2.RegExReplacementValue = ""
        BrowseResultsPopulationSettings1.BrowseColumns.AddRange(New MicroFour.StrataFrame.UI.Windows.Forms.BrowseColumnItem() {BrowseColumnItem1, BrowseColumnItem2})
        BrowseResultsPopulationSettings1.DisplayFieldNames.AddRange(New String() {"cust_FirstName", "cust_LastName"})
        Me.BrowseResultsLayout = BrowseResultsPopulationSettings1
        Me.BusinessObjectType = "LookUpControlSample_BO.CustomersBO"
        BrowseDialogLayoutSettings1.AllowFormResize = True
        BrowseDialogLayoutSettings1.BottomPanelContents = MicroFour.StrataFrame.UI.BrowseDialogLayoutType.BrowseResults
        BrowseDialogLayoutSettings1.FormSize = New System.Drawing.Size(833, 636)
        BrowseDialogLayoutSettings1.LeftSplitterDistance = 153
        BrowseDialogLayoutSettings1.ShowBottomPanel = True
        BrowseDialogLayoutSettings1.ShowSidePanel = False
        BrowseDialogLayoutSettings1.SidePanelContents = MicroFour.StrataFrame.UI.BrowseDialogLayoutType.InformationPanel
        BrowseDialogLayoutSettings1.SideSplitterDistance = 450
        BrowseDialogLayoutSettings1.TopPanelContents = MicroFour.StrataFrame.UI.BrowseDialogLayoutType.SearchFields
        Me.FormLayout = BrowseDialogLayoutSettings1

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