CustomPlaces

4 posts, 0 answers
  1. wang
    wang avatar
    7 posts
    Member since:
    Oct 2017

    Posted 16 Mar Link to this post

    Hello.

    I need directly selected the path like 'DeskTop', 'Videos' or other in the custom place pane sometimes in my application.

    Is there has a way to return the selected custom place path in custom place pane?

  2. Martin Ivanov
    Admin
    Martin Ivanov avatar
    2511 posts

    Posted 18 Mar Link to this post

    Hello Wang,

    If I understood you correctly, you have some custom places defined in the dialog and you want an API that allows you to get and set the selection in the custom places? Can you confirm that this is your case? If not, can you provide some more details on the topic?

    Regards,
    Martin Ivanov
    Progress Telerik

    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
  3. wang
    wang avatar
    7 posts
    Member since:
    Oct 2017

    Posted 18 Mar in reply to Martin Ivanov Link to this post

    yes right.
    I want  to know whether a method that  allows me to get and set the selection in the custom places
  4. Martin Ivanov
    Admin
    Martin Ivanov avatar
    2511 posts

    Posted 23 Mar Link to this post

    Hello Wang,

    The custom places pane of the file dialogs is not selectable itself. This means that it doesn't track a selected item. Instead, when you click an item from the custom places, the dialog is navigated to the corresponding directory. This said, you can get the currently selected directory and match it with the ones in the custom places collection. If the collection contains it, so a custom place is selected. The same is valid for the opposite direction - get a path from the custom places and open it in the dialog.

    To achieve this, you can set the InitialDirectory property of the file dialog just before the ShowDialog() call. I hope this helps. 

    Regards,
    Martin Ivanov
    Progress Telerik

    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Back to Top