Skip to content

Instantly share code, notes, and snippets.

Created October 13, 2020 12:08
What would you like to do?
using System;
using iOSOTPEntrySample;
using iOSOTPEntrySample.iOS;
using UIKit;
using Xamarin.Forms;
using Xamarin.Forms.Platform.iOS;
[assembly: ExportRenderer(typeof(OtpEntry), typeof(OtpEntryRenderer))]
namespace iOSOTPEntrySample.iOS
public class OtpEntryRenderer : EntryRenderer
protected override void OnElementChanged(ElementChangedEventArgs<Entry> e)
if (UIDevice.CurrentDevice.CheckSystemVersion(12, 0) && Control != null)
Control.TextContentType = UITextContentType.OneTimeCode;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment