Note that there are some explanatory texts on larger screens.

plurals
  1. POC# Change text on click event
    primarykey
    data
    text
    <p>I have a field that currently changes text on a mouse click. This field is on multiple pages of my report, but clicking it only changes the text for that page. Here is my code for that:</p> <pre><code> const string sShowDetail2 = "Show Cumulative"; const string sHideDetail2 = "Hide Cumulative"; ArrayList expandedValues2 = new ArrayList(); // This function returns a value indicating whether a certain // category's details should be expanded. bool ShouldShowDetail2(int CategoryID) { return expandedValues2.Contains(CategoryID); } private void lbShowHide2_BeforePrint(object sender, PrintEventArgs e) { XRLabel label = (XRLabel)sender; if (ShouldShowDetail2((int)label.Tag)) { label.Text = sHideDetail2; } else { label.Text = sShowDetail2; } } private void lbShowHide2_PreviewClick(object sender, PreviewMouseEventArgs e) { // Obtain the category's ID stored in the label's Tag property. int index = (int)e.Brick.Value; // Determine whether the current category's details are shown. bool showDetail2 = ShouldShowDetail2(index); // Toggle the visibility of the category's details. if (showDetail2) { expandedValues2.Remove(index); } else { expandedValues2.Add(index); } </code></pre> <p>Now I have another field that I need to simply toggle all instances of the field(every page) on click. I do not need it to read the tag of the particular one I clicked because it will be changing all of them at the same time. My problem is that I don't know how to get them all to change on mouse click. How could I modify the code above to change all instances of the label?</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload