I have a some problem with xamarin binding project.
I got error message below from vs2017 when I was build Android binding project.
Class does not implement interface method
of course, I have found some tips to solve this problem through editing Metadata.xml
but, It is not working. because I have no experience about this.
so. please, I want you to watch my source attached file.
I would upload tow files.
one of them is binding project made by vs2017 including jar.
and then anther one is original jar sdk to bind into my android project.
binding project download link : http://cloud-wr-sg1.acronis.com/links/8E2127FA6223CFC1DA19AE89FB393BAF
original jar file download link :
http://cloud-wr-sg1.acronis.com/links/705ADB4D99254F8490FD3B1D1AACEA34
I need help. I'm in emergency.
You can read the official documents: Java Bindings Metadata and Troubleshooting Bindings. For your scenario, you can add a additional file in your binding library for example like this:
namespace Com.Skp.Tmap
{
partial class TMapView
{
void DraggingAnimateThread.IDraggingCallback.Zoom(float p0, bool p1)
{
}
void DraggingAnimateThread.IDraggingCallback.Rotate(float p0)
{
}
}
}
Related
Trying to start a project (Xamarin Android) of another developer.
The application is compiled successfully, first view shown correctly, it's okay.
But after a moment, then I get an error:
MvvmCross.Platform.Exceptions.MvxIoCResolveException: Failed to resolve type MvvmCross.Core.ViewModels.IMvxAppStart
Visual studio doesn't show any more information about the error, the debugger points to an empty string in MvxSimpleIoCContainer class.
Before opening the project reinstall VS, Xamarin, Android SDK etc.
This project is absolutely correct, on another computer was working perfectly and without this exception. Unfortunately i have no access to those computer.
I will be glad to any prompts.
Error mesage:
Visual Studio after clicking "break":
I had the same issue,my problem was in the core'dll' app.cs
namespace Core
{
public class App : MvxApplication
{
public override void Initialize()
{
CreatableTypes()
.EndingWith("Service")
.AsInterfaces()
.RegisterAsLazySingleton();
RegisterAppStart<ViewModels.FirstViewModel>();
I had no RegisterAppStart<ViewModels.FirstViewModel>(); line, change to use your first view.
I am trying to use MvvmCross to create a Windows Universal App, with the latest UWP bits (RTM). In App.xaml.cs, when I attempt to run -
var start = Mvx.Resolve<IMvxAppStart>();
start.Start();
I get a "System.AccessViolationException" -
Message: "Attempted to read or write protected memory. This is often an indication that other memory is corrupt"
I've created a sample project to reproduce the problem, it contains -
A Portable Class Library (Test.NewCore), which targets ".NET Framework 4.6" and "Windows 10".
A "Universal Windows" app (Test.Uwp), which targets "Windows 10 (10.0; Build 10240)"
I am using the latest nuget pre-release packages, "MvvmCross 4.0.0-beta3" and I believe I set it up properly (I looked at the examples here: https://github.com/MvvmCross/MvvmCross/tree/4.0/nuspec
You can download the test project here: http://1drv.ms/1G6w2m3
The full stack trace is below -
System.AccessViolationException was unhandled
HResult=-2147467261
Message=Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
Source=Windows
StackTrace:
at Windows.UI.Xaml.Controls.Frame.Navigate(Type sourcePageType, Object parameter)
at Cirrious.MvvmCross.WindowsUWP.Views.MvxWindowsViewPresenter.Show(MvxViewModelRequest request)
at Cirrious.MvvmCross.WindowsUWP.Views.MvxWindowsMainThreadDispatcher.RequestMainThreadAction(Action action)
at Cirrious.MvvmCross.ViewModels.MvxNavigatingObject.ShowViewModel[TViewModel](IMvxBundle parameterBundle, IMvxBundle presentationBundle, MvxRequestedBy requestedBy)
at Cirrious.MvvmCross.ViewModels.MvxAppStart`1.Start(Object hint)
at Test.Uwp.App.OnLaunched(LaunchActivatedEventArgs e)
InnerException:
I am using Windows 10 RTM and Visual Studio 2015 RTM, no beta bits (except for MvvmCross).
What am I doing wrong?
I absolutely love MvvmCross and I'm beginning to port an existing Windows 8.1 / Windows Phone 8.1 solution to Uwp - just doing some exploratory research on using the latest MvvmCross bits with Uwp.
Thanks for any help!
#ehuna
The view that you are using is not correct and the AccessViolation that you get is - admittedly - no help at all. The problem seems to be that the runtime does not find the View that you specified and crashes with an obscure exception.
The TestView.xaml looks like
<views:MvxWindowsPage
x:Class="Test.Uwp.Views.View1"
...
but it should be
<views:MvxWindowsPage
x:Class="Test.Uwp.Views.TestView"
Respectively your TestView.xaml.cs looks like
public sealed partial class TestView : MvxWindowsPage<TestViewModel>
{
public TestView()
{
}
}
but it should look like this
public sealed partial class TestView : MvxWindowsPage
{
public TestView()
{
this.InitializeComponent();
}
}
Then everything will work fine. Interesting insight that I gained: MvxWindowsPage<TestViewModel> does not seem to work at all.
This is what I found, which may be different.
I create a UWP app (project1), add a UWP library (project2), and project1 reference project2.
In the library add a page. In project1 app.xaml.cs, change rootFrame.Navigate(typeof(MainPage), e.Arguments) to rootFrame.Navigate(typeof(Project2.MainPage), e.Arguments) so that it navigate to the page in project2.
Run and got the exception.
Workaround:
In project1 app.xaml, add the following to create an instance of the page (as a resource, which doesn't matter):
xmlns:project2="using:project2"
<Application.Resources>
<ResourceDictionary>
<project2:MainPage x:Key="MainPage"></view:MainPage>
</ResourceDictionary>
</Application.Resources>
Run the app, it works.
So looks like the reason for the exception was caused by the page in the other project is not instantiated yet. If you instantiate it in app.xaml, it works.
I'm trying to use MuPDF from Github for Windows phone 8. The Author MishaUliutin mentioned about sample project in a comment of issue. So I downloaded Repository code from here.
I tried to build the project but I am getting error namespace 'PhoneBootstrapper' could not be found on PhoneBootstrapper class. I'm not sure about the PhoneBootstrapper class or Is there any thing else that I'm missing.
Edit:
I tried to add the downloaded project to another new project using Add existing project option and then try to add reference from solution it gives the fallowing error in image.
For this I unblocked the dll file suggested from here http://vkslabs.com/reference-higher-version-incompatible-assembly-added-project/ (not working)
&
- I downloaded the sample project from Here [ https://bitbucket.org/mishauliutin/pdf-reader-for-wp8-public/downloads ]
- And sample project itself having a Solution file(.sln).
- I try build it & gives me the PhoneBootstrapper error.
So.. I believe phoneBootstapper is class from Caliburn.Micro which is added as nuget package to the project.
Has anyone been able to get an extension up and running Expression Blend + Sketchflow preview? I'm looking for an example project.
I was following this article, but it is a bit outdated.
So far I:
Created a .Net 4.5 class library project
Added a reference to the Microsoft.Expression.Extensibility.dll in the new Blend Preview directory
Set my project to deploy to the appropriate Addins directory
Setup Visual Studio to run the new Blend.exe for debugging
Hooked up MEF and inherited IPlugin as in the example
But my plugin doesn't seem to load and no breakpoints are hit.
After reading your question I decided to start working on a new version of that tutorial.
A few things to get you started right away.
I've created the basic plugin like this:
using System.ComponentModel.Composition;
using Microsoft.Expression.Extensibility;
namespace Demo.Extension
{
[Export(typeof (IPackage))]
public class Demo : IPackage
{
public void Load(IServices services)
{
}
public void Unload()
{
}
}
}
Make sure you:
place the plugins in ...\Blend Preview\extensions
run visual studio as administrator to be able to deploy to that folder during debug
implement the IPackage instead of IPlugin
Got it working by following the demo here.
I used the few modifications above, and put things in the Blend Preview directory.
i am just starting to develop in monodroid , i know android and c# too. i have created android app using viewflow example. so i have now viewflow library 's jar file , i have included that .jar file in my monodroid java binding library as defined in http://docs.xamarin.com/Android/Guides/Advanced_Topics/Java_Integration_Overview/Binding_a_Java_Library_(.jar). But when i build that java library project i have got following error.. i have stuck with this almost 3 hrs.
'Org.Taptwo.Android.Widget.ViewFlow' does not implement inherited abstract member 'Android.Widget.AdapterView.RawAdapter.set'
This has been filed as bug 11279. The workaround is to add a file to your binding project with the following contents:
using Android.Runtime;
namespace Org.Taptwo.Android.Widget {
partial class ViewFlow {
protected override Java.Lang.Object RawAdapter {
get {return Adapter.JavaCast<Java.Lang.Object>();}
set {Adapter = value.JavaCast<global::Android.Widget.IListAdapter>();}
}
}
}
Change the namespace and type name as appropriate to fix other binding projects.