Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FilePickerContracts - OnCachedFileUpdaterActivated does not fire on Before Access. #842

Closed
Lazzarus opened this issue Feb 12, 2018 · 5 comments

Comments

@Lazzarus
Copy link

OnCachedFileUpdaterActivated never fires on the BeforeAccess Example. (Open Picker -> Pick cached file)

To replicate.
Stick a break point on OnCachedFileUpdaterActivated in App.xaml.custom.cs and CachedFileUpdaterUI_FileUpdateRequested in CachedFileUpdaterPage.xaml.cs
Select Open from a any Text app and select the file picker contracts app for the source
Select option 3 Pick cached file
Add file to basket.
Select open. The breakpoints are never hit

Looking at the code, there's a method AddFileButton_Click in FileOpenPicker_CachedFile.xaml.cs
This looks to be incorrect and hiding the problem.
It creates a new file and then populates the file with some text.

For this example I would expect the CachedFileUpdate to either populate the text or update the text when
ReadActivationMode.BeforeAccess fires the OnCachedFileUpdaterActivated event.

The result is the file opens in the third party app with content but at no time is the cachedFileUpdater used.

@Lazzarus Lazzarus changed the title FilePickerContracts: OnCachedFileUpdaterActivated does not fire on Before Access. FilePickerContracts - OnCachedFileUpdaterActivated does not fire on Before Access. Feb 12, 2018
@oldnewthing
Copy link
Member

This looks like it's a platform issue, but I've asked the samples team to look at it anyway. You'll probably have better luck (and responsiveness) contacting Developer Support:

  1. Visit http://aka.ms/storesupport and sign-in with your Microsoft account
  2. Under the “App Development” section choose "Windows 10 universal app development", then choose the appropriate problem type and category to get engaged through a formal support channel.

@iagrav
Copy link

iagrav commented Jul 2, 2018

BeforeAccess CFU trigger only covers MostRecentlyUsed List and FutureAccess List accesses and not any type of access. CFU won't trigger for this type of access. I'm updating the sample to have a proper BeforeAccess example.

@Lazzarus
Copy link
Author

Lazzarus commented Sep 5, 2018

@iagrav Any update on this issue?

@oldnewthing
Copy link
Member

One language was updated, but the others haven't been done yet.

@oldnewthing
Copy link
Member

Fix is published in release v7.0.2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants