Okay, I got the choice list to work. Here is my next problem, and
please bear with me again. I would like to be able to display the
product name but use the <@startrow> of the current search that the
choice list is in. Sorry about my thick headedness. Since the current
search displays 5 products at a time using startrow, I would like to
display the results in the current search by utilizing the dropdown.
I am assigning the product name to an array, but would like some help
with adding a count to the returns when assigning the array for the
choicelist and adding that to the choicelist. I created a counter,
but would like to the to the existing array. i.e.
<option value="1">Product Name 1</option>
<option value="2">Product Name 2</option>
<option value="3">Product Name 3</option>
etc.
This is what I have so far....
In the first search, I am assigning the array with these values. This
product numbers then product name. Don't need the product numbers but
a simple count here woudl do for <@VAR resultSet[*,1]>
<@ASSIGN NAME="ArrayW" VALUE="<@ARRAY ROWS='<@NUMROWS>' COLS='3'>"
SCOPE="USER">
<@ASSIGN NAME=ArrayW[*,1] "<@VAR resultSet[*,1]>">
<@ASSIGN NAME=ArrayW[*,2] "<@VAR resultSet[*,2]>">
<@ASSIGN NAME="totalrows" VALUE="<@NUMROWS>">
Then I am doing a looping count called m_counter
I think this is where I would need to update the current array is it
not? This is where I would like to change the <@VAR
NAME='ArrayW[*,1]'> to a simple count so I could use it for startrow
in the next search.
In the choice list, I now have the options right, but need the values
to be the count. Is this making sense? Or is there a better way to do
this?
<@CHOICELIST NAME="pick" SIZE=1 TYPE=select VALUES="<@VAR
NAME='ArrayW[*,1]'>" OPTIONS="<@VAR NAME='ArrayW[*,2]'>"
SELECTED="selected">
(sorry, a typo)
For the simple drop down, it's going to look more like this
given: you have an array: @@myArray and a field = myName
<@choicelist name="myName" size=1 options=@@myArray[*,1]
Values=@@myARray[*,2] >
of course, myArray can be all of your products that is held in a
persistent variable, or the product of a prior query. It can be
filtered, sorted, and tortured to you preference. It's just got 2
columns that you care about, and you're using one for the values and
one for the display.
On May 31, 2005, at 9:43 AM, [EMAIL PROTECTED] wrote:
Okay, it seems that choicelist is the way to go. I have never had a
need for this, so please bear with me as I muddle through this.
I have built an array that has 2 values, one is the product number,
the other is the name of the product. I cannot see how to display
the product name as what the user sees and the product number as
the value when selected. Anyone know if this can be done?
In other words
<option value="<product number>">Blue Widgets</option>
Thanks
look at <@choicelist>
On May 31, 2005, at 8:52 AM, [EMAIL PROTECTED] wrote:
Witango 2000
Is it possible to build a dropdown to be used on another search.
In other words, I have a page that displays 5 products per page.
That's easy enough. But I need to have a dropdown of all the
products on that same page. I have been trying to do this by
bulding an array, but cannot seem to get it to work right. The
problem is the array has to be built on a search before the main
search page.
Logic would dictate that
Array search -- > build an array for all products
Main search --> Need to drop in a form dropdown here for all
products even though this search only displays 5 products at a
time.
Is this making sense? All I get is a list of the products, but I
cannot seem to get them to display in a drop down. Seems that it
reverts to just text.
____________________________________________________________________ __ __
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf
_____________________________________________________________________ ___
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf
______________________________________________________________________ __
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf
________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf
________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf