Skip to content

Commands with selectedItem or itemID as CommandParameter #17316

Answered by maxkatz6
bsdRuf asked this question in Q&A
Discussion options

You must be logged in to vote

Command parameter needs to be of object type, not integer, see https://learn.microsoft.com/en-us/dotnet/api/system.windows.input.icommand.execute?view=net-8.0#system-windows-input-icommand-execute(system-object).

You can cast it in runtime though, inside of the command, if you always pass an integer there.

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by bsdRuf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants