Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Questions showing custom UI messages #141

Open
walkesh opened this issue Jun 5, 2023 · 0 comments
Open

Questions showing custom UI messages #141

walkesh opened this issue Jun 5, 2023 · 0 comments

Comments

@walkesh
Copy link

walkesh commented Jun 5, 2023

Description

We are using your Plugin.NFC in our xamarin forms application. Our application is multilingual, so we are using resource files to display the translated strings. We noticed there are strings displayed that are part of your library. We are looking for a way to show those text strings in the language of the phone (at least, French, German, Spanish and Dutch). I saw on the repository information page, it mentions about showing custom strings by calling the following SetConfiguration() ,method.

  1. Is it possible to use this call to implement translations for the nfc related strings?
  2. Do you have any sample code showing when it is best to call this SetConfiguration to use french or other strings?

// Custom NFC configuration (ex. UI messages in French)
CrossNFC.Current.SetConfiguration(new NfcConfiguration
{
Messages = new UserDefinedMessages
{
NFCSessionInvalidated = "Session invalidée",
NFCSessionInvalidatedButton = "OK",
NFCWritingNotSupported = "L'écriture des TAGs NFC n'est pas supporté sur cet appareil",
NFCDialogAlertMessage = "Approchez votre appareil du tag NFC",
NFCErrorRead = "Erreur de lecture. Veuillez rééssayer",
NFCErrorEmptyTag = "Ce tag est vide",
NFCErrorReadOnlyTag = "Ce tag n'est pas accessible en écriture",
NFCErrorCapacityTag = "La capacité de ce TAG est trop basse",
NFCErrorMissingTag = "Aucun tag trouvé",
NFCErrorMissingTagInfo = "Aucune information à écrire sur le tag",
NFCErrorNotSupportedTag = "Ce tag n'est pas supporté",
NFCErrorNotCompliantTag = "Ce tag n'est pas compatible NDEF",
NFCErrorWrite = "Aucune information à écrire sur le tag",
NFCSuccessRead = "Lecture réussie",
NFCSuccessWrite = "Ecriture réussie",
NFCSuccessClear = "Effaçage réussi"
}
});

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant