Why do you think that setting the Value of a parameter to "ParameterDirection.Output" is going to magically cause it to become an output parameter? Do you think that setting it to your username magically makes it your user?
Try this:
cmd.Parameters.Add("@UserId", SqlDbType.SmallInt).Direction = ParameterDirection.Output;