xamarin.android

MvvmCross Dynamic Text Value Conversion

≡放荡痞女 提交于 2020-01-13 17:06:14
问题 As far as I know, MvvmCross localization plugin provides "static" engine. I use the following binding as an example from Conference: local:MvxBind="{'Text'{'Path':'TextSource','Converter':'Language','ConverterParameter':'SQLBitsXApp'}}" I want to be able to change SQLBitsXApp to SQLBitsXApp2 dynamically. The goal is to find the localized text related to days enum. Is there a way to do this dynamically ? 回答1: You're correct - the default MvxLanguageConverter used in that binding is really

TPL on PCL for MvvmCross for PCL Profile 78

你离开我真会死。 提交于 2020-01-13 10:54:10
问题 Trying to use PCL for mvvmcross with TPL by Profile 78 (regarding question TPL on PCL of mvvmcross) On iOS project it's working, but NOT for android . here the Error: Exception while loading assemblies: System.IO.FileNotFoundException: Could not load assembly 'System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.Perhaps it doesn't exist in the Mono for Android profile? File name: 'System.Runtime.dll' at Xamarin.Android.Tuner.DirectoryAssemblyResolve So, does

TPL on PCL for MvvmCross for PCL Profile 78

微笑、不失礼 提交于 2020-01-13 10:54:08
问题 Trying to use PCL for mvvmcross with TPL by Profile 78 (regarding question TPL on PCL of mvvmcross) On iOS project it's working, but NOT for android . here the Error: Exception while loading assemblies: System.IO.FileNotFoundException: Could not load assembly 'System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.Perhaps it doesn't exist in the Mono for Android profile? File name: 'System.Runtime.dll' at Xamarin.Android.Tuner.DirectoryAssemblyResolve So, does

Search Dialog in Mono Android

梦想与她 提交于 2020-01-13 09:06:09
问题 I'm trying to implement a search dialog in a Mono Android app per the documentation here: http://developer.android.com/guide/topics/search/search-dialog.html I have an activity that the user should be able to search from: [Activity (Label = "MyActivity", MainLauncher = true, Icon = "@drawable/icon", Theme = "@style/MyStyle")] [MetaData ("android.app.default_searchable", Value = ".SearchActivity")] public class MainActivity : BaseActivity {... I have a searchable activity (where the heavy

convert JSON to contentvalues

北城余情 提交于 2020-01-13 06:42:07
问题 Is there an easy way to get JSON from a webservice and put it into my SQLite DB in C# mono for android (xamarin)? There are some tedious ways to do it but I want something quick and elegant. 回答1: The question is old, but here is the equivalent code of @gghuffer in Java: public static ContentValues objectToContentValues(Object o) throws IllegalAccessException { ContentValues cv = new ContentValues(); for (Field field : o.getClass().getFields()) { Object value = field.get(o); //check if

Is Reactive Extensions 2.1 PCL compatible with Xamarin?

生来就可爱ヽ(ⅴ<●) 提交于 2020-01-13 05:54:06
问题 Riddle me this: Can the new PCL version of Reactive Extensions be made to work with Xamarin? If so, how? 回答1: Nope. But check out https://github.com/mono/rx/tree/rx-oss-v2.1/Rx/NET/Source/Rx_Xamarin for versions that do work. 回答2: Yes it is possible. At the moment, you will need to switch to the beta channel of the Xamarin tools which implement Mono 3.0. This can be done via Tools > Options > Xamarin in Visual Studio 2012. Xamarin.Android 4.7 Information Xamarin.iOS 6.3 Information The

Create android spinner dynamically in Xamarin

佐手、 提交于 2020-01-13 02:44:09
问题 I'm a newbie to Xamarin and I want to create a simple application to get familiar with Xamarin. I want to create and populate the spinner and display it's options dynamically. I have seen the documentation here but it is not created programmatically. Any help will be apreaciated var levels = new List<String>() { "Easy", "Medium", "Hard", "Multiplayer" }; var adapter = new ArrayAdapter<String>(this, Android.Resource.Layout.SimpleSpinnerItem, levels); adapter.SetDropDownViewResource(Android

MvvmCross localization: switch at runtime

馋奶兔 提交于 2020-01-12 05:50:08
问题 Is there a way to change the current language to another one at runtime ? For example: be able to switch when a button is clicked or when starting the app, get the user language and switch. How to tell the plugin to check the user language at startup ? Thanks in advance for your help. 回答1: Is there a way to change the current language to another one at runtime ? yes, call builder.LoadResources(whichLanguage) on your MvxTextProviderBuilder.cs For example: be able to switch when a button is

APK that is not signed with the upload certificate Google Play Store [duplicate]

旧时模样 提交于 2020-01-11 13:27:10
问题 This question already has answers here : I lost my .keystore file? (11 answers) Closed 2 years ago . I developed an app using Xamarin.Forms, and I would publish the app to Google Play Store, I generated the APK and Store key as the following document (https://docs.microsoft.com/en-us/xamarin/android/deploy-test/release-prep/?tabs=windows) from Visual Studio, but when I upload the APK file to Google Play Store, I get the following error. Upload failed You uploaded an APK that is not signed

Upgrading MvvmCross to 5.2 shows error on CustomAndroidPresenter

∥☆過路亽.° 提交于 2020-01-11 11:57:04
问题 After upgrading MvvmCross from 5.1 to 5.2 , my CustomAndroidPresenter.cs is throwing a build error. What is causing this? CustomAndroidPresenter.cs: namespace TestPrjDroid { public class CustomAndroidPresenter : MvxAndroidViewPresenter { public override void Show(MvxViewModelRequest request) { if (request != null && request.PresentationValues != null) { if (request.PresentationValues.ContainsKey("MyCustomFlag")) { // Get intent from request and set flags to clear backstack. var intent = base