This is a migrated thread and some comments may be shown as answers.

Hide "X" close button on Window

10 Answers 538 Views
Window
This is a migrated thread and some comments may be shown as answers.
Todd
Top achievements
Rank 1
Todd asked on 24 Feb 2009, 07:25 PM
Using the RadWindow control, is there a way to hide the "X" button in the upper right hand corner?

Thanks in advance,

Todd

10 Answers, 1 is accepted

Sort by
0
Hristo Borisov
Telerik team
answered on 25 Feb 2009, 12:20 PM
Hi Todd,

Yes, you can achieve this by configuring the CloseMode property. The enumerator gives you the following functionality.

Close - RadWindow closes if the user clicks the close button.
Hide - RadWindow hides.
None - RadWindow doesn't have close button.

Thank you for contacting us, I hope this will resolve your problem.

Best wishes,
Hristo Borisov
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Kavi
Top achievements
Rank 1
answered on 03 Aug 2010, 02:03 PM
Also is there a way to hide the titlebar too?

Silverlight version: 2010.1.422.1030
0
Salim
Top achievements
Rank 1
answered on 06 Jan 2016, 04:15 PM
What's the code ? I have  page that I open as a window and I want to hidethe x (close button)
0
Nasko
Telerik team
answered on 07 Jan 2016, 07:37 AM
Hello Salim,

In order to hide the Close button of RadWindow the CanClose property needs to be set to false. Please, check the following article from our help documentation that provides a detailed information how to achieve this:
http://docs.telerik.com/devtools/silverlight/controls/radwindow/features/closing

Hope this helps.

Regards,
Nasko
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Luke Daugherty
Top achievements
Rank 1
answered on 19 Jan 2016, 09:26 PM
I actually just did this. Setting CanClose  to false works, but it does not prevent the Esc key from closing the dialog which is annoying. It should.
0
Nasko
Telerik team
answered on 22 Jan 2016, 08:47 AM
Hello Luke,

You are probably referring to one of the predefined dialogs that have a built in functionality to close when the Escape button gets pressed. If that is the case in order to disable that functionality you could use an attached property and subscribe to the KeyDown event for the dialogs and handle that event - thus the dialogs won't be closed when Escape gets pressed. For RadAlert you need also to modify the Style because it has an input binding to the Escape key - that input binding needs to be removed.

We have created a sample project that demonstrates the described above approach and you could run and evaluate it.

We hope this will help you.

Regards,
Nasko
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Luke Daugherty
Top achievements
Rank 1
answered on 22 Jan 2016, 01:50 PM
Thanks. I had already figured this out. The point is if you set CanClose to false one would assume that would prevent the user from closing the dialog through ALL default actions (x button AND Esc). Also, I am not using a pre-defined dialog. It is my own control that implements RadWindow, displayed using ShowDialog.
0
Nasko
Telerik team
answered on 25 Jan 2016, 01:05 PM
Hi Luke,

The observed by you behavior is not an expected one when RadWindow is used - it does not have an implemented internal logic for closing when Escape gets pressed, because of that we assume you were using one of the predefined windows. Please, check the attached video that demonstrates that.

Could you please, try to isolate the observed by you behavior in a sample and send it to us - thus we could be able to continue our investigation?

We are looking forward to hearing from you.

Regards,
Nasko
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Luke Daugherty
Top achievements
Rank 1
answered on 25 Jan 2016, 02:52 PM
On further investigation this behavior was not due to the RadWindow. Sorry for the confusion. Feel free to remove my posts from this topic to avoid confusion for others reading this topic.
0
Nasko
Telerik team
answered on 25 Jan 2016, 02:55 PM
Hi Luke,

We are glad to hear that you were able to resolve your issue and now everything is working as expected.

If you have any additional questions or concerns regarding Telerik controls, please do not hesitate to contact us.

Regards,
Nasko
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
Window
Asked by
Todd
Top achievements
Rank 1
Answers by
Hristo Borisov
Telerik team
Kavi
Top achievements
Rank 1
Salim
Top achievements
Rank 1
Nasko
Telerik team
Luke Daugherty
Top achievements
Rank 1
Share this question
or