I have a Radwindow used as UserControl, in this window I have a button, when you press the button the RadWindow.Confirm appears, at that moment, the confirm is showed sometimes centered and sometimes not.
Please check this page: http://demos.telerik.com/silverlight/#Window/APC to confirm the problem.
Do I need to use something different?
Thank you.
15 Answers, 1 is accepted
Thanks
We are aware of this problem with RadWindow control and it is logged in our system. You can track its change and vote for this bug here - http://www.telerik.com/support/pits.aspx#/public/silverlight/7983.
To work around the problem, I would suggest go handle the Loaded event and set custom values for Top and Left properties in order to center the window manually.
George
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
I understand there is a bug, are you planning to fix this problem? Could you give me an example?
Thank you.
Could you please provide me an example?
Thank you.
Please, refer to the attached project that illustrates how to override top and left properties of RadWindow. All you need is to set ContentTemplate for the RadCofirm and handle the Loaded event. In the loaded event handler you could make the necessary calculations and set top/left.
Hope this helps.
George
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
is not working when I already have a RadWindow opens.
My scenario is a RadWindow, already open and when I click in a button, I open a RadConfirm window. The RadConfirm opens but I can't see the window, I only see the title bar.
Please take a look into the attached file.
Thank you.
I tried to reproduce the problem, but to no avail - please, refer to the attached sample.
Providing us with a sample application in which we can observe the issue will be very helpful in determining the source of the issue.
George
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
Is working now.
Thank you.
Are you going yo fix this issue in the next version? to avoid adding this code in the app.xaml?
Thank you.
Thank you.
We haven't estimated the issue yet and I cannot say when it will be resolved. You could track it in the PITS system, but most probably it won't be done for the Q3 release.
For the problem with the RadWindow in windows 7 theme, I am not able to reproduce it - please, refer to our online examples - http://demos.telerik.com/silverlight/#Window/Theming
Do you use a custom template for the RadWindow? Could you please post it?
George
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
<
telerik:RadWindow
x:Class
=
"Etelesolv.Telemanager.TME.UserControls.SelfService.EmployeeEmailWindow"
xmlns:telerik
=
"http://schemas.telerik.com/2008/xaml/presentation"
xmlns:controls
=
"clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls"
Width
=
"400"
Height
=
"200"
Header
=
""
>
<
Grid
x:Name
=
"LayoutRoot"
Margin
=
"2"
>
<
Grid.RowDefinitions
>
<
RowDefinition
Height
=
"35"
/>
<
RowDefinition
Height
=
"*"
/>
<
RowDefinition
Height
=
"35"
/>
</
Grid.RowDefinitions
>
<
Border
Grid.Row
=
"0"
Style
=
"{StaticResource BorderStyleCornerRadiusOnTop}"
>
<
Border.Background
>
<
LinearGradientBrush
EndPoint
=
"0.5,1"
StartPoint
=
"0.5,0"
>
<
GradientStop
Color
=
"#FFD1D1D1"
Offset
=
"0"
/>
<
GradientStop
Color
=
"#00F5FAFC"
Offset
=
"1"
/>
</
LinearGradientBrush
>
</
Border.Background
>
<
TextBlock
x:Name
=
"TextBlockTitle"
Text
=
"Update Email"
TextWrapping
=
"Wrap"
Margin
=
"10,10,0,5"
Grid.Column
=
"0"
Grid.Row
=
"0"
Style
=
"{StaticResource ModuleTitleStyle}"
/>
</
Border
>
<
Border
x:Name
=
"BorderEmployee"
Grid.Column
=
"0"
Grid.Row
=
"1"
BorderBrush
=
"LightGray"
BorderThickness
=
"1"
Margin
=
"7,5,7,5"
VerticalAlignment
=
"Stretch"
>
<
StackPanel
Grid.Column
=
"0"
Grid.Row
=
"1"
>
<
sdk:Label
Style
=
"{StaticResource Calibri13BoldLabelStyle}"
Grid.Column
=
"0"
Grid.Row
=
"1"
Margin
=
"10,15,10,0"
x:Name
=
"lblEMail"
Content
=
"E-mail:"
VerticalAlignment
=
"Center"
/>
<
TextBox
x:Name
=
"TextBoxEmail"
Grid.Column
=
"0"
Grid.Row
=
"1"
Margin
=
"10,0,10,0"
VerticalAlignment
=
"Center"
/>
</
StackPanel
>
</
Border
>
<
StackPanel
Orientation
=
"Horizontal"
HorizontalAlignment
=
"Center"
Grid.Row
=
"2"
>
<
Button
x:Name
=
"SaveButton"
Content
=
"Save"
Click
=
"SaveButton_Click"
Width
=
"115"
Height
=
"23"
Margin
=
"0,0,10,0"
/>
<
Button
x:Name
=
"SendButton"
Content
=
"Send"
Click
=
"SendButton_Click"
Width
=
"115"
Height
=
"23"
Margin
=
"0,0,10,0"
/>
<
Button
x:Name
=
"CancelButton"
Content
=
"Cancel"
Click
=
"CancelButton_Click"
Width
=
"115"
Height
=
"23"
/>
</
StackPanel
>
</
Grid
>
</
telerik:RadWindow
>
and this is the cs code:
public partial class EmployeeEmailWindow : RadWindow
{
#region Constructors
public EmployeeEmailWindow()
{
LocalizationManager.Manager = new LocalizationRadControls();
InitializeComponent();
}
#endregion
/// <
summary
>
/// Load
/// </
summary
>
/// <
param
name
=
"employeeId"
></
param
>
public void Load(int employeeId, string employeeEmail)
{
this.ShowDialog();
this.employeeId = employeeId;
this.employeeEmail = (string.IsNullOrEmpty(employeeEmail)) ? "": employeeEmail;
this.ConfigControls();
}//end of Load
/// <
summary
>
/// ConfigControls
/// </
summary
>
private void ConfigControls()
{
this.TextBoxEmail.Text = employeeEmail;
}//end of ConfigControls
#region Private/Public Methods
private void SaveButton_Click(object sender, RoutedEventArgs e)
{
if (this.IsValidEmail(this.TextBoxEmail.Text))
{
InvokeOperation<
string
> operation =
context.EmployeeEmailUpdate(this.employeeId, this.TextBoxEmail.Text);
operation.Completed += (s, x) =>
{
if (!operation.HasError)
{
if (operation.Value == "")
{
MessageBox.Show(TMEGlobals.GetLanguageString("operationSuccessful"));
this.Close();
this.OnEmailUpdated();
}
}
else
{
MessageBox.Show(operation.Value);
}
};
}
}
private void SendButton_Click(object sender, RoutedEventArgs e)
{
}
private bool IsValidEmail(string email)
{
if (string.IsNullOrEmpty(this.TextBoxEmail.Text))
{
return true;
}
if (!Validator.IsValidEmail(this.TextBoxEmail.Text))
{
MessageBox.Show(TMEGlobals.GetLanguageString("invalidEmail"));
return false;
}
return true;
}
private void CancelButton_Click(object sender, RoutedEventArgs e)
{
this.Close();
}
/// <
summary
>
/// OnEmailUpdated
/// </
summary
>
protected virtual void OnEmailUpdated()
{
if (EmailUpdated != null)
{
EmailUpdated(this, new EventArgs());
}
}//end of OnEmailUpdated
#endregion
#region Private/Public Members
public event EventHandler EmailUpdated;
public string EmployeeEmailChanged;
private EmployeeDomainContext context = new EmployeeDomainContext();
private int employeeId;
private string employeeEmail;
#endregion
}
Thank you.
I tried to reproduce the problem with the provided code, but to no avail. You can find attached the sample plus a demo. Please, let me know if I do something wrong.
George
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
Even with your example... I see the square in the top left corner of the window. Try to open the same example, but change before the background of your page to black (not the radwindow). You will be able to see it.
Thank you.
I can confirm that this bug is fixed for the Q3 Beta release. Please, download and give it a try and let me know if you still encounter any issues with the RadWindow control.
I am glad to assist you further.
George
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>