We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

progress bar won''t show up on grid control

Thread ID:





39146 Dec 28,2005 11:22 PM Dec 29,2005 08:31 PM Windows Forms 6
Tags: GridControl
Administrator [Syncfusion]
Asked On December 28, 2005 11:22 PM

Hi, i tried to add create a progress bar and display it on a grid control. The progress bar is given a information of the starting rowindex and colIndex and the length of the progress bar. But when i run this add function, the grid only merge the cells together without showing the progress bar. I''ve attacted the screen shots private void AddBar(int rowIndex, int colIndex, int length, Cars objCar) { this.gridControl1.BeginUpdate(); GridStyleInfo style = gridControl1[rowIndex, colIndex]; GridProgressBarInfo timeBar = style.ProgressBar; style.ProgressBar.BackSegments = false; timeBar.BackgroundStyle = Syncfusion.Windows.Forms.Tools.ProgressBarBackgroundStyles.Tube; style.ProgressBar.BackTubeEndColor = System.Drawing.Color.White; style.ProgressBar.BackTubeStartColor = System.Drawing.Color.DodgerBlue; style.ProgressBar.BackGradientStartColor = System.Drawing.Color.DodgerBlue; style.ProgressBar.BackGradientEndColor = System.Drawing.Color.White; style.ProgressBar.BackMultipleColors = new System.Drawing.Color[0]; style.ProgressBar.GradientEndColor = System.Drawing.Color.Lime; style.ProgressBar.GradientStartColor = System.Drawing.Color.Red; style.CellType = "ProgressBar"; style.CellAppearance = GridCellAppearance.Raised; style.ProgressBar.ProgressStyle = ProgressBarStyles.MultipleGradient; style.ProgressBar.ForeColor = System.Drawing.Color.DodgerBlue; style.ProgressBar.TextVisible = false; style.ReadOnly = true; style.ProgressBar.ProgressValue = 100; this.gridControl1.RowHeights[rowIndex] = 23; this.gridControl1.CoveredRanges.Add(GridRangeInfo.Cells(rowIndex, colIndex, rowIndex, length)); gridControl1.EndUpdate(true); this.gridControl1.Refresh(); }


Administrator [Syncfusion]
Replied On December 29, 2005 12:44 AM

Hi Wyejin, Your code works fine. Here is a sample with your same code. Can you find any issue? Regards, Calvin.


Administrator [Syncfusion]
Replied On December 29, 2005 01:10 AM

yup, Is the same codes, but it won''t display the progress bar, is there some other way to create a progress bar programically on a gridcontrol with specific start columns index, row index and the length of the progress bar? :( >Hi Wyejin, > >Your code works fine. Here is a sample with your same code. Can you find any issue? > >Regards, >Calvin.


Administrator [Syncfusion]
Replied On December 29, 2005 03:41 AM

Hi Wyejin, Here your code works fine in the sample which I have attached earlier. Can I know the Syncfusion version which your working with? So that I can try to reproduce your mentioned issue here. Thanks, Calvin.

Administrator [Syncfusion]
Replied On December 29, 2005 04:05 AM

Thanks Calvin for reply me this quick.. :) My syncfusion version is I''ve tried on a empty forms but the code i''m trying and it works. Then i tried to create the Forms that all over again. THe problem still exist. I''ve attacthed my screenshots of my UI and my codes together. I hope this might be helpful for you. Thanks again :)


Administrator [Syncfusion]
Replied On December 29, 2005 07:37 AM

Hi Wyejin, In your GenerateNewBar function set style.ReadOnly to true after seting all the style properties. It will work fine. Regards, Calvin. private void GenerateNewBar(int rowIndex, int colIndex, int length) { ................ .................... //style.ReadOnly = true; //Dont Set style to Read Only here. style.CellType = "ProgressBar"; style.CellAppearance = GridCellAppearance.Raised; style.ReadOnly = true; //You can set it here. //this.gridSchedule.RowHeights[rowIndex] = 23; this.gridSchedule.CoveredRanges.Add(GridRangeInfo.Cells(rowIndex, colIndex, rowIndex, length)); //this.gridSchedule.EndUpdate(true); //this.gridSchedule.Refresh(); this.gridSchedule.Model.EndUpdate(true); //this.gridSchedule.RefreshRange(GridRangeInfo.Cells(rowIndex, colIndex, rowIndex, length)); this.gridSchedule.Refresh(); }

Administrator [Syncfusion]
Replied On December 29, 2005 08:31 PM

Thank you so much for helping me out.. It works!! :)


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.