Je suis en train d'écrire une application Windows Phone 8.1 et je souhaiterais avoir la possibilité d'associer des événements Tapped (par exemple pour la grille). J'ai lu beaucoup d'articles et de réponses, mais toutes les solutions ne fonctionnent pas dans ma situation. Existe-t-il une alternative aux déclencheurs (System.Windows.Interactivity) ou Command pour WP 8.1?Binding Tapped event
1
A
Répondre
1
Merci pour l'intérêt, mais j'ai trouvé la solution. J'étais probablement trop fatigué et j'ai oublié d'ajouter une référence au SDK Behaviors. Cela fonctionne très bien maintenant.
<Page
xmlns:i="using:Microsoft.Xaml.Interactivity"
xmlns:core="using:Microsoft.Xaml.Interactions.Core" ...>
et simple utilisation de la commande:
<SomeControl ...>
<i:Interaction.Behaviors>
<core:EventTriggerBehavior EventName="Tapped">
<core:InvokeCommandAction Command="{Binding MyCommand}" />
</core:EventTriggerBehavior>
</i:Interaction.Behaviors>
</SomeControl>
Questions connexes
- 1. jQuery Event Binding
- 2. Java Event Binding
- 3. Comprendre WPF Binding CommandParameter = "{Binding}"
- 4. {Binding}, {Binding Data.XXX}, {Binding Path = XXX} et d'autres dans WPF
- 5. Dois-je coder les événements ItemClick et Tapped?
- 6. Event listener vs event handler
- 7. CQRS dépendances Event Event Cohérence
- 8. Drop Event Listbox
- 9. Binding ContentTemplate
- 10. Binding StringFormat
- 11. CFSELECT Binding
- 12. DataGridView Binding
- 13. Binding ArrayCollections of Arrays
- 14. Silverlight TextBinding TextChanged Event
- 15. événement tweet Twitter binding/reconsolidation
- 16. WPF-MVVM: Handeling Event depuis DataGrid Style
- 17. Différence entre {Binding PropertyName} et {Binding Path = PropertyName}
- 18. Quelle est la différence entre {binding} et {binding Account}?
- 19. dropdownlist event
- 20. WPF Canvas Binding
- 21. Binding Issue constructeur viewmodel
- 22. Log Parser Early Binding
- 23. Adresses IP JBoss Binding
- 24. WPF Binding Help
- 25. Parent propriété Binding
- 26. objet Binding à listview
- 27. WPF Binding StringFormat
- 28. Tkinter Global Binding
- 29. JQuery DatePicker Binding
- 30. Silverlight Binding convertisseur
Pouvez-vous nous dire ce que vous avez essayé, mais ne fonctionne pas? Ce sera plus facile pour nous de vous aider. – Bun