Select Computers Interface

Batch, ASP, JScript, Kixtart, etc.
Forum rules
Do not post any licensing information in this forum.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
User avatar
Posts: 182
Joined: Fri Jan 30, 2009 12:37 am

Select Computers Interface

Post by rasimmer »

It's to quiet in here today, so I thought I would throw something out here that I'd like to add to one of my HTA's. I have no idea what they call this GUI or applet in an application, but you have textarea on the left, buttons in the middle and a textarea on the right. The left textbox typically has your options (computers in this case) and you would click the ">" button to move a selected computer to the right textbox or click an object in the right pane and "<" to move it back over. I hope you know what I'm talking about and I was just curious if someone had a code example laying around. :o)

Posts: 14573
Joined: Tue May 22, 2007 9:57 am
Answers: 1

Select Computers Interface

Post by jvierra »

Here is a simple one - OK I lied. It took 7 lines of code.

Code: Select all

<script language="vbscript">
    Sub moveit()
        if leftlist.selectedIndex >= 0 Then
            Set opt = leftlist.options(leftlist.selectedIndex)
        End If
    End Sub
    <select id="leftlist" size="5"  ondblclick="moveit">
    <option>item 1</option>
    <option>item 2</option>
    <option>item 3</option>
    <option>item 4</option>
    <option>item 6</option>
    <select id="rightlist" size="5">
jvierra2009-03-04 12:54:48