This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Display multi select checkboxes on State forms

Has anyone figured out how to get multi select checkbox to show ALL the values on a state form and not just the selected values?

Even as checkboxes it only lists the values that were checked and no way to actually show a checked box.

I can write javascript to put a disabled checked box in front of each values listed but how would I get the full list?

I am using this as a list of tasks rather than creating a separate item for each task so a use can update one item and check off what is done.   But I want to also display the values that are not checked off yet in the base forms.

  • 0  

    One option may be to compromise and use a list box display option instead on the state form, but it is not top of mind if it shows the whole list. An extreme option could be to create an Advanced Report (https://knowledgebase.serena.com/InfoCenter/index?page=content&id=S141342&actp=search&viewlocale=en_US&searchid=1643911836745) to gain access to the list of values in TS_SELECTIONS and then use tricks on top of that to visualize the data.

  • 0 in reply to   

    I used an embedded JavasciptWidget and <DIV> tag along with a separate ASP page on the webapp server and got the job done.  

     

    <script>

        var xmlHttp = new XMLHttpRequest();

        var theURL = "https://..../ToDoList.asp?DoneTasks={ToDoTaskList}&TaskType={ToDoTaskType[ID]}"

        xmlHttp.open( "GET", theURL, false ); // false for synchronous request

        xmlHttp.send();

        document.getElementById("ToDoListDIV").innerHTML=xmlHttp.responseText;

    </script>

    <DIV id="ToDoListDIV"></DIV>

     

    The asp page checks the boxes that are done from the ToDoTaskList field and filters the entire list using ToDoTaskType[ID] to only display the task checkboxes that are needed. 

    ASP Script

    <%
    tasktype=Request.QueryString("TaskType")
    DoneTasks=Request.QueryString("DoneTasks")

    %>
    <%
    Dim Recordset1
    Dim Recordset1_cmd
    Dim Recordset1_numRows

    Set Recordset1_cmd = Server.CreateObject ("ADODB.Command")
    Recordset1_cmd.ActiveConnection = MM_ABShelpProd_STRING
    Recordset1_cmd.CommandText = "SELECT * FROM TSM_SRC_ITSBUCUSTOMERTASKS WHERE TS_ID<>0 AND TS_TODOTASKTYPE='"&TaskType&"'"
    Recordset1_cmd.Prepared = true

    Set Recordset1 = Recordset1_cmd.Execute
    Recordset1_numRows = 0
    %>
    <%
    Dim Repeat1__numRows
    Dim Repeat1__index

    Repeat1__numRows = -1
    Repeat1__index = 0
    Recordset1_numRows = Recordset1_numRows + Repeat1__numRows
    %>


    <%
    While ((Repeat1__numRows <> 0) AND (NOT Recordset1.EOF))
    %>
    <input name="ToDoListoption" type="checkbox" value="1" <%if InStr(DoneTasks,Recordset1("TS_TITLE"))>0 then%> checked="checked"<%end if%> disabled="disabled" /> <%=(Recordset1("TS_TITLE"))%><br />

    <%
    Repeat1__index=Repeat1__index+1
    Repeat1__numRows=Repeat1__numRows-1
    Recordset1.MoveNext()
    Wend
    %>

    <%
    Recordset1.Close()
    Set Recordset1 = Nothing
    %>