portable-class-library

Tab Control in MVVM CROSS

不羁的心 提交于 2019-12-04 21:16:55
We are developing an application that supports WP, Android & iOS operating systems using Xamarin framework. Need to create two tabs Filter & Search, using filter tab will select some values from drop down, date picker and load the listing grid of search tab. But I couldn't able to find a sample application for creating tab control in MVVM CROSS (Portable Library Class). ViewModel Class: public class SearchWOViewModel : MvxViewModel { public readonly ISearchWOService _serachwo; public SearchWOViewModel() { Filter = new FilterViewModel(_serachwo); Search = new SearchViewModel(_serachwo); }

Can you/How to specify Editor at runtime for PropertyGrid (for PCL)?

别来无恙 提交于 2019-12-04 19:14:37
I wrote a PCL with custom objects in there, and then I create a GUI that handles the objects from the PCL... and I try to use PropertyGrid to edit the properties... I've already read that in order for the grid to know what to do with the object, I need to specify the EditorAttribute as well as providing a TypeConverter... but I don't think I could add those 2 in the PCL... Is there a way to handle this at the GUI level, like telling the PropertyGrid to use a specific type of Editor/TypeConverter at runtime? I went through the list of available function/properties of the grid and doesn't look

A common class library consumed by both .NET Core and .Net 4.5.2

回眸只為那壹抹淺笑 提交于 2019-12-04 18:14:42
问题 I'm fairly new to .Net Core, but have made a working Asp.Net Core WebAPI site - now I want to share some code with another project... I have Visual Studio 2015 with Update 3 installed. I have DotNetCore.1.0.0-VS2015Tools.Preview2.exe installed from here. I would like to create a shared library (PCL) that can be consumed by two other libraries - it only contains primitive classes/interfaces with no other dependencies. One of the consuming libraries is a new vanilla project targeting

Xamrin.Forms Entry Cell How to change font size for Placeholder

∥☆過路亽.° 提交于 2019-12-04 16:49:01
I am thinking if i can change font size for placeholder on EntryCell without change fontSize for Text on EntryCell ? Is There away to change font size for Placeholder without change font size for Text Code = new EntryCell { Label = "Code:*", Text = "", Keyboard = Keyboard.Default, Placeholder = "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" }; Here is a custom renderer for android. Here I'm modifying the HintTextColor(placeholder). You can modify the font in a similar way. using System; using Xamarin.Forms.Platform.Android; using Xamarin.Forms; using communityhealth; using Android.Graphics; using

Is there any way to use RNGCryptoServiceProvider class in C# Portable class Library

回眸只為那壹抹淺笑 提交于 2019-12-04 16:24:27
I am working on a encryption algorithm and using cryptography for this. I want to make this portable, but didn't find any way to resolve this class. You can also use the full managed Bouncy Castle Library. A Portable Class Library Patch is available here: http://www.bouncycastle.org/jira/browse/BMA-107 A pre-build of Bouncy Castle 1.7 with the PCL Patch is available here for example: https://github.com/dnauck/Portable.Licensing/tree/master/lib Dan You Didn't mention what profile you are looking for In any case... RNGCryptoServiceProvider it seems to exist only in .NET Framework Supported in: 4

Implementing custom exceptions in a Portable Class Library

有些话、适合烂在心里 提交于 2019-12-04 16:05:26
问题 When designing custom exceptions for .NET, MSDN provides these guidelines. In particular, the guidelines state that a custom exception: should be serializable, i.e. implement ISerializable and be decorated with the [Serializable] attribute, and should implement the (de)serialization constructor, i.e. protected CustomException(SerializationInfo info, StreamingContext context) . However, in a Portable Class Library neither of SerializableAttribute , ISerializable and SerializationInfo are

Is Reactive Extensions 2.1 PCL compatible with Xamarin?

烈酒焚心 提交于 2019-12-04 15:34:19
Riddle me this: Can the new PCL version of Reactive Extensions be made to work with Xamarin? If so, how? Nope. But check out https://github.com/mono/rx/tree/rx-oss-v2.1/Rx/NET/Source/Rx_Xamarin for versions that do work. 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 ReactiveUI project should have all of the libraries that you need. Here is a link to the libraries folder on their

MonoTouch: creating multiplatform apps using Portable Class Libraries

青春壹個敷衍的年華 提交于 2019-12-04 13:45:52
问题 My scenario: trying to port a small part of an application created by our company from native code (ObjC for iOS / Java for Android) to C-Sharp. The project will interact with our webservices. Goal of this project is figuring out how feasible it is to port our whole app to Mono. To create URLs, I'd like to use String.Format() . I thought it'd be a wise idea to put this 'service layer' inside a Portable Class Library (PCL) since I don't expect this code to change across platforms. Sadly, it

Produce a .NET 4.0 library from a PCL Project where code is identical

懵懂的女人 提交于 2019-12-04 13:12:26
It's quite frustrating, I have a Portable Class Library (PCL) library that had to drop .NET 4.0 in the profile to have access to the right API's "in PCL land". However, these API's do exist in .NET 4.0, such that if the exact same code is in a .NET 4.0 project it compiles just fine. I want a minimal ongoing maintenance way to recompile the code in this PCL project to .net 4.0 so I can include it in a Nuget package. With minimal conditional adjustments to the .csproj , an msbuild project can be created to compile a portable library solution to produce additional .net 4.0 profile binaries. Build

Exception using await HttpClient.GetAsync in Portable Class Library

馋奶兔 提交于 2019-12-04 12:47:11
I have Portable Class Library(net40+sl4+win8+wp71) with code: public static async Task<Dictionary<string, FeedItem>> GetFeeds() { try { string data; using (HttpMessageHandler handler = new HttpClientHandler()) { using (HttpClient httpClient = new HttpClient(handler)) { data = await httpClient.GetStringAsync(FeedsUrl + Guid.NewGuid()).ConfigureAwait(false); } } if (data != null) { //... } return null; } catch { return null; } } Microsoft.Bcl, Microsoft.Bcl.Async and Microsoft.Net.Http are referenced. I use this library in Windows 8 Metro app. Then I debugg app through VS2012, it is ok. But when