Jump to content
Software FX Community

Using the Grid in a custom control


vaioklm
 Share

Recommended Posts

We are evaluating GridFX for use in our software shop.  The majority of our code is encapsulated in custom controls.  Ideally, we would like to be able to use GridFX within these custom controls.  However, the Grid does not function properly when created within one of these controls as opposed to putting it directly on the ASPX web form.  The grid will render fine, but the various features like grouping, hiding, sorting, etc... either do not work at all, or work intermittently.  I will include a very simplistic example of what we are trying to do.  Do you think it will be possible to use the Grid in this manner?

Public

Class pnlOrderViewInherits System.Web.UI.WebControls.Panel

Dim WithEvents gfxNonPharm As GridFX.WebForms.Grid

Protected Overrides Sub CreateChildControls() MyBase.CreateChildControls() gfxNonPharm = New GridFX.WebForms.Grid gfxNonPharm.EnableViewState = True Controls.Add(gfxNonPharm)End Sub

Private Sub gfxNonPharm_DataBinding(ByVal sender As Object, ByVal e As System.EventArgs) Handles gfxNonPharm.DataBinding Dim netBLPhysician As pgBLPhysician.clsOrders = Nothing Dim dvData As Data.DataView

netBLPhysician =

New pgBLPhysician.clsOrders dvData = netBLPhysician.GetNonPharm(ConnectionString, VisitIntId, PersonIntID, ManIntID, UserIntId, CareGiverIntId, StartDate, EndDate, VisitsBack,   OrderType, OrderCode).Tables(0).DefaultView gfxNonPharm.DataSource = dvDataEnd Sub

Private Sub pnlOrderView_Init(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Init EnsureChildControls()End SubPrivate Sub pnlOrderView_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load If Not Page.IsPostBack Then   gfxNonPharm.DataBind() End IfEnd Sub

End

Class
Link to comment
Share on other sites

Hi,

Thanks for using Grid FX.  I am psyched to see someone using Grid inside some custom controls.  It should work in custom controls. I used your test example (had to use different data though), and saw only one problem where the sort descending icon didn't show up.  I didn't have any other strange behaviors, which is strange. Do have the latest version? Do me a favor and check at http://support.softwarefx.com/ShowInteractive.aspx?Product=GridFX10&option=0

Regardless, I did see some strangeness and will look deeper into it.  Grid FX will, once I'm done, work smoothly inside a custom control.  So please bear with me and we'll get it taken care of.

Thanks!  Talk to you soon.

Link to comment
Share on other sites

It looks like my version was up to date with the exception of some documentation.  A specific example of some of the strangeness I'm seeing would be if I try to hide a column; the column hides fine, but if I then try to hide another column the first column hidden reappears and the second column is not hidden.  Once this has happened, I can then group on a column, but I can't expand the groups.

We do use ChartFX in our shop and I currently have 6.2 installed.  The powers that be are working with your company on a licensing agreement, so we haven't upgraded to the latest version yet.  I know that the charting is pretty tightly integrated into the Grid.  Could my older version of ChartFX be a problem?

 Thanks

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...