Exemplo n.º 1
0
    protected void ResultsDataListDataBinding(object sender, EventArgs e)
    {
        _totalVotes = Polls.GetTotalVotes(PollId);

        // Display the # of votes
        var totalVotesLabel = PollFormView.FindControl("TotalVotesLabel") as Label;

        if (totalVotesLabel != null)
        {
            totalVotesLabel.Text = string.Format("{0:d} votes...", _totalVotes);
        }
    }