1
votes

any idea how I can start a native UWP page from a Xamarin Forms page? The reason why I'm asking:

I have a XF application that needs to start a UWP library after a click event. This library provides a special ORC reader. Therefore I created a dependency service to run the platform specific function. What I need now, is to open that UWP page, that contains the "Camera stream" to show the user what he is currently scanning. And this is where I am hanging at the moment.

In my class that is called from the dep. service, I myPage mp = new myPage();

But how can I show the new page?

Frame fr = Window.Current.Content as Frame gives me the error, that this page cannot be converted from a XF Frame to a Window Frame.

Or is there generally another way to handle this? Some advice would be great.

1

1 Answers

1
votes

This sounds like a custom renderer.

Create a new OcrView class in your shared project inherited from View.

Place it on your Xamarin Forms XAML page.

Handle the OCR component in the UWP renderer.

Have a look at the Implementing a View section on this custom renderer overview