Hi!
Can anyone help me with this? Urgent please.
I'm using radButtons. The GradientStyle is Linear. But when I switch forms, all (as in all) the radButtons in all forms change to GradientStyle Solid. I noticed this when we upgraded to Q3 2010.
Thanks,
Ian
Can anyone help me with this? Urgent please.
I'm using radButtons. The GradientStyle is Linear. But when I switch forms, all (as in all) the radButtons in all forms change to GradientStyle Solid. I noticed this when we upgraded to Q3 2010.
Thanks,
Ian
11 Answers, 1 is accepted
0

Ian
Top achievements
Rank 1
answered on 05 Jan 2011, 02:16 PM
Hi,
Additional information.
I noticed that the gradient property just changed to solid (in all buttons. I even added new button and the gradient style changes too) even though there is no code to programmatically change it.
I temporarily created a work around because we urgently need it for presentation. But I hope I can really fix the issue. Thank you.
My work around:
ButtonElement.ButtonFillElement.PropertyChanged += new PropertyChangedEventHandler(ButtonFillElement_PropertyChanged);
void ButtonFillElement_PropertyChanged(object sender, PropertyChangedEventArgs e)
Kind regards,
Ian
Additional information.
I noticed that the gradient property just changed to solid (in all buttons. I even added new button and the gradient style changes too) even though there is no code to programmatically change it.
I temporarily created a work around because we urgently need it for presentation. But I hope I can really fix the issue. Thank you.
My work around:
ButtonElement.ButtonFillElement.PropertyChanged += new PropertyChangedEventHandler(ButtonFillElement_PropertyChanged);
void ButtonFillElement_PropertyChanged(object sender, PropertyChangedEventArgs e)
{
var fillPrimitive = sender as Telerik.WinControls.Primitives.FillPrimitive;
if (e.PropertyName == "GradientStyle")
{
if (fillPrimitive != null && fillPrimitive.GradientStyle == Telerik.WinControls.GradientStyles.Solid)
fillPrimitive.GradientStyle = Telerik.WinControls.GradientStyles.Linear;
}
}
Kind regards,
Ian
0

Richard Slade
Top achievements
Rank 2
answered on 05 Jan 2011, 05:07 PM
Hi Ian,
I saw that someone else had reported somethig similar recently but I was unable to replicate it at the time. Please can you tell nme a bit more about your situation? E.g. Switching forms.. Is this an MDI app, using radDock? Just two different forms open?
If you can give me a scenario, I'll see if I can replicate it.
Richard
I saw that someone else had reported somethig similar recently but I was unable to replicate it at the time. Please can you tell nme a bit more about your situation? E.g. Switching forms.. Is this an MDI app, using radDock? Just two different forms open?
If you can give me a scenario, I'll see if I can replicate it.
Richard
0

Ian
Top achievements
Rank 1
answered on 05 Jan 2011, 05:52 PM
Hi Richard,
Thank you for your reply.
The scenario is this. The management decided to change the design of the current application. We found out that some of the designs they wanted can be done using Telerik controls. We changed the old 3rd party controls with Telerik. (In most cases, we changed it in the InitializedComponent() procedure). The buttons are then set to linear gradient style.
These buttons are in custom user controls (most of the user controls contains a complete screen for user interaction) where in depending on user actions, the custom user controls are shown or hidden (or loaded or unloaded).
When showing (loading etc) the custom user control, the gradient style just changed to solid even if there's no code to change it. (I tracked it first using the RadControlSpyForm and then using the snippet I posted earlier. The changing also happened when I load a new form (show dialog) and/or when I just disable enable a button (e.g. repeat button).
I search the entire solution of ".GradientStyle = GradientStyles.Solid" to make sure there's no code that programmatically change it to solid. I only found 2 in
Then I search for this..."GradientStyles.Solid" and I found codes same as the sample below in the designer part.
this.keyGrid.HeaderGradientStyle = Telerik.WinControls.GradientStyles.Solid;
We are not using MDI and radDock. This happened after we updated to Q3 2010 and when I tried to changed some element properties of the one of the buttons. I already reverted the changes but still, the problem is there.
I hope I explained it clearly. The change property event of the gradient style fire each time I show/hide/load/unload a form or a custom user control even without explicitly changing it.
Thank you very much,
Ian
Thank you for your reply.
The scenario is this. The management decided to change the design of the current application. We found out that some of the designs they wanted can be done using Telerik controls. We changed the old 3rd party controls with Telerik. (In most cases, we changed it in the InitializedComponent() procedure). The buttons are then set to linear gradient style.
These buttons are in custom user controls (most of the user controls contains a complete screen for user interaction) where in depending on user actions, the custom user controls are shown or hidden (or loaded or unloaded).
When showing (loading etc) the custom user control, the gradient style just changed to solid even if there's no code to change it. (I tracked it first using the RadControlSpyForm and then using the snippet I posted earlier. The changing also happened when I load a new form (show dialog) and/or when I just disable enable a button (e.g. repeat button).
I search the entire solution of ".GradientStyle = GradientStyles.Solid" to make sure there's no code that programmatically change it to solid. I only found 2 in
private void dataGrid_CellFormatting(object sender, CellFormattingEventArgs e)I commented it but still, the problem is there.
{ if (bfValue >= bfRed)}{
e.CellElement.DrawFill = true;
e.CellElement.GradientStyle = GradientStyles.Solid;
e.CellElement.BackColor = colourRed;
e.CellElement.BackColor2 = colourRed;
}
else if (bfValue >= bfYellow)
{
e.CellElement.DrawFill = true;
e.CellElement.GradientStyle = GradientStyles.Solid;
e.CellElement.BackColor = colourYellow;
e.CellElement.BackColor2 = colourYellow;
}
Then I search for this..."GradientStyles.Solid" and I found codes same as the sample below in the designer part.
this.keyGrid.HeaderGradientStyle = Telerik.WinControls.GradientStyles.Solid;
We are not using MDI and radDock. This happened after we updated to Q3 2010 and when I tried to changed some element properties of the one of the buttons. I already reverted the changes but still, the problem is there.
I hope I explained it clearly. The change property event of the gradient style fire each time I show/hide/load/unload a form or a custom user control even without explicitly changing it.
Thank you very much,
Ian
0

Richard Slade
Top achievements
Rank 2
answered on 05 Jan 2011, 06:05 PM
Hi Ian,
I'm afriad I haven't been able to replicate this. I have tried the following
this made no difference as it was already set to linear.
If you can put together a demo that can replicate the issue, and post it here, I'll be happy to take a look.
All the best
Richard
I'm afriad I haven't been able to replicate this. I have tried the following
- Create a form with a RadButton
- On click of the RadButton, launch a second form
- The second form has a user control that contains 3 RadButtons
- On one of the RadButtons in the user control, I explicitly set the GradientStyle to Linear
radButton3.ButtonElement.ButtonFillElement.GradientStyle = Telerik.WinControls.GradientStyles.Linear;
If you can put together a demo that can replicate the issue, and post it here, I'll be happy to take a look.
All the best
Richard
0

Richard Slade
Top achievements
Rank 2
answered on 05 Jan 2011, 06:08 PM
One more thing Ian.
Could you confirm the following: that you are using the Default theme, and that you are using the latest 2010 Q3 SP1 release as there were several UI glitches that were fixed in the latest service pack.
Thanks
Richard
Could you confirm the following: that you are using the Default theme, and that you are using the latest 2010 Q3 SP1 release as there were several UI glitches that were fixed in the latest service pack.
Thanks
Richard
0

Ian
Top achievements
Rank 1
answered on 05 Jan 2011, 06:23 PM
Hi Richard,
We are using the Default theme, and the version we are using is 2010.3 1109. I will try to create a demo after our presentation. Thanks a lot.
Kind regards,
Ian
We are using the Default theme, and the version we are using is 2010.3 1109. I will try to create a demo after our presentation. Thanks a lot.
Kind regards,
Ian
0
Accepted

Richard Slade
Top achievements
Rank 2
answered on 05 Jan 2011, 06:27 PM
Hi Ian,
I'd suggest upgrading to 1215 (SP1). Here are the release notes for SP1. As you can see, there were visual issues fixed in the Control Default theme.
The upgrade is painless and there shouldn't be anything in there that will cause you an issue as far as I'm aware.
Hope that helps
Richard
I'd suggest upgrading to 1215 (SP1). Here are the release notes for SP1. As you can see, there were visual issues fixed in the Control Default theme.
The upgrade is painless and there shouldn't be anything in there that will cause you an issue as far as I'm aware.
Hope that helps
Richard
0

Ian
Top achievements
Rank 1
answered on 06 Jan 2011, 10:42 AM
Noted. Thank you very much.
Ian
Ian
0

Richard Slade
Top achievements
Rank 2
answered on 06 Jan 2011, 11:13 AM
No problem Ian. If you upgrade and find that this works, please remember to mark as answer so others can find the solution too.
All the best
Richard
All the best
Richard
0

Ian
Top achievements
Rank 1
answered on 06 Jan 2011, 01:29 PM
Hi Richard,
I already installed the SP1 and removed the work around code. My problem is now solved. Thank you very much.
Kind regards,
Ian
I already installed the SP1 and removed the work around code. My problem is now solved. Thank you very much.
Kind regards,
Ian
0

Richard Slade
Top achievements
Rank 2
answered on 06 Jan 2011, 01:32 PM
Glad that worked for you Ian
Richard
Richard