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

Find RadPane after LoadLayout

8 Answers 71 Views
Docking
This is a migrated thread and some comments may be shown as answers.
Weliton Flor
Top achievements
Rank 1
Weliton Flor asked on 19 Mar 2010, 01:36 AM
Hello,

I'm creating a RadPane and Save the Layout. 
When I click the button to create this RadPane again, first I check if already been created and not re-created, just set Focus().

When I open the application, collects the serialized layout and performs LoadLayout(). It works without problems. 
When I click to open the RadPane and try to find but does not work, will only work when I change the state of RadPane, for example, leave it floating and dock again.

Tks

8 Answers, 1 is accepted

Sort by
0
Miroslav Nedyalkov
Telerik team
answered on 19 Mar 2010, 02:52 PM
Hello Weliton,

 Could you please provide a sample project that demonstrates the issue and a step-by-step instructions how to reproduce it - this will help us better understand what the problem is and assist you fixing it.

You could also refer to the following blog post that corresponds to your scenario: http://blogs.telerik.com/miroslavnedyalkov/posts/10-03-04/how_to_activate_a_pane_in_the_telerik_docking_control_for_wpf_and_silverlight.aspx.

Greetings,
Miroslav Nedyalkov
the Telerik team

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 Public Issue Tracking system and vote to affect the priority of the items.
0
Weliton Flor
Top achievements
Rank 1
answered on 19 Mar 2010, 04:09 PM
Here is a sample project. 
Download here DOWNLOAD PROJECT

When I click on Open Pane, the application first checks if there is, if exists, creates a pane, if not exists, simply calls the method Focus ().

When I create a pane, unpinned and save the layout, close the application, open again and try to load layout. Aftet, try to Open Pane, not find the pane.

Tks
0
Weliton Flor
Top achievements
Rank 1
answered on 22 Mar 2010, 06:57 PM
Can someone help me?
0
Miroslav Nedyalkov
Telerik team
answered on 24 Mar 2010, 02:58 PM
Hello Weliton,

 What you need to do to fix this problem is to set the SerializationTag attached property to the group, you are referencing in the code-behind.

Sincerely yours,
Miroslav Nedyalkov
the Telerik team

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 Public Issue Tracking system and vote to affect the priority of the items.
0
Weliton Flor
Top achievements
Rank 1
answered on 24 Mar 2010, 03:15 PM
Hi, 

I include SerializationTAG in Group, but now, when I try to open page, is not finding and create new pane and gets two panes in the same place, .

Here is a sample project with SerializationTAG. 
Download here DOWNLOAD PROJECT

Tks.
0
Miroslav Nedyalkov
Telerik team
answered on 25 Mar 2010, 03:26 PM
Hello Weliton,

 I tried the project you sent, but seems that it works as expected. Could you please tell us what do you think is not working correctly? I went trough the code using your break points and it seems that creates the pane only when there is no pane in the docking with this name.

If you could send us a step-by-step instructions what you and what you expect to happen every step this would be very helpful.

Best wishes,
Miroslav Nedyalkov
the Telerik team

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 Public Issue Tracking system and vote to affect the priority of the items.
0
Weliton Flor
Top achievements
Rank 1
answered on 25 Mar 2010, 04:02 PM
OK,

- First I run the application on Browser.
- Create PANE and SaveLayout

- Close Browser

- Run Application again
- LoadLayout

-- After, when I try to create PANE, can´t find PANE saved.
0
Miroslav Nedyalkov
Telerik team
answered on 25 Mar 2010, 05:17 PM
Hi Weliton,

 Now I see. The problem is that when the Docking control is loading the layout, it cannot find your pane in the default docking to associate it with the loaded pane (with the SerializationTag) and creates an empty pane with the saved settings. What you need to do to override this behavior is to handle the ElementLoading event of the Docking control and to use the event args to create your pane. Please find the attached project - I edited your project and fixed this issue.

One more thing - I noticed that you are using a memory stream in order to save or load the layout. You don't need to do this - you could use directly the isolated storage file stream. I changed this in the example to demonstrate the idea.

Hope this helps!

Regards,
Miroslav Nedyalkov
the Telerik team

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 Public Issue Tracking system and vote to affect the priority of the items.
Tags
Docking
Asked by
Weliton Flor
Top achievements
Rank 1
Answers by
Miroslav Nedyalkov
Telerik team
Weliton Flor
Top achievements
Rank 1
Share this question
or