Its need System.Windows.Navigation namespace in using section and it requires specific type of argument for initialization like below
public Page1()
{
InitializeComponent();
PageFunction<string> obj = new PageFunction<string>();
obj.Return += obj_Return;
}
void obj_Return(object sender, ReturnEventArgs<string> e)
{
}