SaveFileDialog doesnt allow you to open shortcuts to folders

1 Answer 15 Views
FileDialogs
Martin
Top achievements
Rank 2
Martin asked on 10 Oct 2025, 02:57 PM

I recently found that you cant follow shortcuts to folders in the RadSaveFileDialog. We have several end users that have created shortcuts to folders and when they try to open those folders the dialog just selects the shortcut file instead and returns.

There is an option called DereferenceLinks in the OpenFileDialog which seems to do the job but this is not available on any other dialogs.

Is there a work around for this or can that option be made available on the other dialogs too?

1 Answer, 1 is accepted

Sort by
0
Stenly
Telerik team
answered on 16 Oct 2025, 10:03 AM

Hello Martin,

Currently, the RadSaveFileDialog component does not fully support folder shortcuts, however, this behavior can be achieved with a bit of custom code.

More specifically, you could subscribe to the Loaded event of the RadSaveFileDialog and retrieve the ExplorerControl element via the ChildrenOfType extension method. Then, cache it into a field or a property. After that, you could subscribe to the PreviewMouseDoubleClick event of RadSaveFileDialog and check whether the DataContext of the e.OriginalSource property is of the type of FileInfoWrapper. If it is and its IsShortcut property is true, set the CurrentDirectoryPath property of the cached ExplorerControl to the ShortcutLocation property of the FileInfoWrapper object. This way, navigating to a folder via its shortcut will be achieved.

The following code snippets showcase this suggestion's implementation:

//Caching the ExplorerControl instance
private ExplorerControl explorerControl;

//Retrieving the ExplorerControl instance
private void SaveFileDialog_Loaded(object sender, RoutedEventArgs e)
{
    RadSaveFileDialog radSaveFileDialog = (RadSaveFileDialog)sender;

    ExplorerControl explorerControl = radSaveFileDialog.ChildrenOfType<ExplorerControl>().FirstOrDefault();

    if (explorerControl != null)
    {
        this.explorerControl = explorerControl;
    }
}
//Navigation logic on double click of a shortcut
private void SaveFileDialog_PreviewMouseDoubleClick(object sender, MouseButtonEventArgs e)
{
    FrameworkElement frameworkElement = e.OriginalSource as FrameworkElement;

    if (frameworkElement != null)
    {
        FileInfoWrapper fileInfoWrapper = frameworkElement.DataContext as FileInfoWrapper;

        if (fileInfoWrapper != null)
        {
            if (fileInfoWrapper.IsShortcut)
            {
                RadSaveFileDialog radSaveFileDialog = (RadSaveFileDialog)sender;

                this.explorerControl.CurrentDirectoryPath = fileInfoWrapper.ShortcutLocation;

                e.Handled = true;
            }
        }
    }
}

With this being said, I attached a sample project for you to test, which contains this suggestion's implementation.

Regards,
Stenly
Progress Telerik

Your perspective matters! Join other professionals in the State of Designer-Developer Collaboration 2025: Workflows, Trends and AI survey to share how AI and new workflows are impacting collaboration, and be among the first to see the key findings.
Start the 2025 Survey
Tags
FileDialogs
Asked by
Martin
Top achievements
Rank 2
Answers by
Stenly
Telerik team
Share this question
or