navigation
a webmaster learning community
     Home    Register     Search      Help      Login    
FrontPage Alternative
Sponsors

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Free FrontPage Templates

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

 

List boxes Display ALL

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> ASP and Database >> List boxes Display ALL
Page: [1]
 
prasmile2002

 

Posts: 33
Joined: 2/14/2005
Status: offline

 
List boxes Display ALL - 2/14/2005 16:51:30   
Hi,

I have two list boxes one has the list1 and the other list2 pulling data out of a database. How do I add "ALL" in both the lists since it's dynamic list and display all records..

Thanks
Raj
Spooky

 

Posts: 26606
Joined: 11/11/1998
From: Middle Earth
Status: offline

 
RE: List boxes Display ALL - 2/14/2005 17:44:07   
hard code the first item (outside of the database loop) so that you always have the code : <option>all</option>

_____________________________

If you arent part of the solution, then there is good money to be made prolonging the problem

§þ:)


(in reply to prasmile2002)
prasmile2002

 

Posts: 33
Joined: 2/14/2005
Status: offline

 
RE: List boxes Display ALL - 2/14/2005 18:02:19   
Hey I am sorry I wasn't clear ..I already hardcoded that option but I wanted to know how to display all the values from the table..

I know it's select * from table;

But I want to know where you'll put it in the code..

Thanks
Raj


(in reply to Spooky)
Spooky

 

Posts: 26606
Joined: 11/11/1998
From: Middle Earth
Status: offline

 
RE: List boxes Display ALL - 2/14/2005 18:11:48   
Using the code :
<option value="%">all</option>

Will allow you to do a "LIKE" search of the database when the "all" options is selected.
eg using the variable from the select boxes :
select * from table where column1 LIKE '"&box1&"' AND column2 LIKE '"&box2&"'

"%" is a wildcard

_____________________________

If you arent part of the solution, then there is good money to be made prolonging the problem

§þ:)


(in reply to prasmile2002)
prasmile2002

 

Posts: 33
Joined: 2/14/2005
Status: offline

 
RE: List boxes Display ALL - 2/14/2005 18:23:24   
Thanks ..but I tried that too..but my records don't pull up..Here's the code for your reference..Thanks for your quick responses

******************
<html>

<head>
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<% ' FP_ASP -- ASP Automatically generated by a Frontpage Component. Do not Edit.
FP_CharSet = "windows-1252"
FP_CodePage = 1252 %>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Insurance</title>
<style type="text/css">
<!--
.style1 {	font-family: Tahoma, Verdana, Georgia;
	font-size: 12px;
	font-weight: bold;
}
.unnamed1 {	font-family: Tahoma, Verdana, Georgia;
	font-size: 12px;
	width: auto;
}
body, td, th {
	font-family: Tahoma, Verdana, Georgia;
	font-size: 12px;
}
.style24 {color: #FFFFFF}
.style26 {
	color: #006633;
	font-weight: bold;
	font-family: Tahoma, Verdana, Georgia;
	font-size: 11px;
	background-color: #FFFFCC;
}
.style28 {
	color: #FF6600;
	font-weight: bold;
	font-family: Tahoma, Verdana, Georgia;
	font-size: 11px;
	background-color: #FFFFCC;
}
.unnamed2 {
	font-family: Tahoma, Verdana, Georgia;
	font-size: 10px;
	color: #006699;
}
.style29 {
	color: #FF9900;
	font-size: 14px;
	font-weight: bold;
}
.style34 {	font-size: 36px;
	color: #006699;
	font-weight: bold;
}
.style35 {
	color: #996600;
	font-weight: bold;
}
.style36 {
	color: #FF0000;
	font-weight: bold;
}
.style39 {color: #336699}
.style40 {color: #7BA428}
-->
</style>
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a.indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a;}}
}

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a)&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers.document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}
//-->
</script>
</head>

<body onLoad="MM_preloadImages('file:///C|/Inetpub/wwwroot/testing_17thjan/images/mlargefont.jpg','file:///C|/Inetpub/wwwroot/testing_17thjan/images/mphysicians.jpg','file:///C|/Inetpub/wwwroot/testing_17thjan/images/msmallfont.jpg','http://mycomp/testing_17thjan/images/mlargefont.jpg','http://mycomp/testing_17thjan/images/mkeyword.jpg')">

<p><nobr class="style1 style6"></nobr></p>
<div id="Layer1" style="position:absolute; width:632px; height:101px; z-index:1; left: -40; top: 0;"><a href="testing_17thjan/index.htm"><img src="testing_17thjan/images/logo.jpg" width="630" height="100" border="0"></a></div>
<p> </p>
<p> </p>
<div id="Layer2" style="position:absolute; width:745px; height:115px; z-index:2; left: 16px; top: 270px; visibility: inherit;">
  <table width="78%" border="0" cellpadding="0" cellspacing="0">
    <thead>
      <tr bgcolor="#006699">
        <td width="10%"><span class="style24"><b>Insurance</b></span></td>
        <td width="2%"><span class="style24"></span></td>
        <td width="8%"><span class="style24"><b> Plan</b></span></td>
        <td width="2%"><span class="style24"></span></td>
        <td width="16%"><span class="style24"><b>Physician</b></span></td>
        <td width="1%"><span class="style24"></span></td>
        <td width="11%"><span class="style24"><b>Effective Date</b></span></td>
        <td width="2%"><span class="style24"></span></td>
        <td width="12%"><span class="style24"><b>Expiring Date</b></span></td>
        <td width="1%"><span class="style24"></span></td>
        <td width="12%"><span class="style24"><b>Provider Type</b></span></td>
        <td width="1%"><span class="style24"></span></td>
        <td width="22%"><span class="style24"><b>Contract Type</b></span></td>
      </tr>
      <tr>
        <td> </td>
        <td> </td>
        <td> </td>
        <td> </td>
        <td> </td>
        <td> </td>
        <td> </td>
        <td> </td>
        <td> </td>
        <td> </td>
        <td> </td>
        <td> </td>
        <td> </td>
      </tr>
    </thead>
    <tbody>
      <!--webbot bot="DatabaseRegionStart" s-columnnames="Insurance,Ins Plan,ParticipatingPhysician,Effective Date,Expiring Date,Provider Type,Contract Type,Field8,Plan" s-columntypes="202,202,202,135,202,202,202,202,202" s-dataconnection="Sample" b-tableformat="TRUE" b-menuformat="FALSE" s-menuchoice s-menuvalue b-tableborder="TRUE" b-tableexpand="TRUE" b-tableheader="TRUE" b-listlabels="TRUE" b-listseparator="TRUE" i-listformat="0" b-makeform="FALSE" s-recordsource s-displaycolumns="Insurance,Ins Plan,ParticipatingPhysician,Effective Date,Expiring Date,Provider Type,Contract Type,Field8,Plan" s-criteria s-order s-sql="SELECT * FROM tabulated WHERE (Insurance =  '::Insurance::') and (ParticipatingPhysician = '::ParticipatingPhysician::')" b-procedure="FALSE" clientside suggestedext="asp" s-defaultfields="Insurance=&ParticipatingPhysician=" s-norecordsfound="No records returned." i-maxrecords="256" i-groupsize="0" botid="2" u-dblib="_fpclass/fpdblib.inc" u-dbrgn1="_fpclass/fpdbrgn1.inc" u-dbrgn2="_fpclass/fpdbrgn2.inc" tag="TBODY" preview="<tr><td colspan=64 bgcolor="#FFFF00" align="left" width="100%"><font color="#000000">This is the start of a Database Results region. The page must be fetched from a web server with a web browser to display correctly; the current web is stored on your local disk or network.</font></td></tr>" startspan --><!--#include file="_fpclass/fpdblib.inc"-->
<% if 0 then %>
<SCRIPT Language="JavaScript">
document.write("<div style='background: yellow; color: black;'>The Database Results component on this page is unable to display database content. The page must have a filename ending in '.asp', and the web must be hosted on a server that supports Active Server Pages.</div>");
</SCRIPT>
<% end if %>
<%
fp_sQry="SELECT * FROM tabulated WHERE (Insurance =  '::Insurance::') OR (ParticipatingPhysician = '::ParticipatingPhysician::')"
fp_sDefault="Insurance=&ParticipatingPhysician="
fp_sNoRecords="<tr><td colspan=9 align=left width=""100%"">No records returned.</td></tr>"
fp_sDataConn="Sample"
fp_iMaxRecords=256
fp_iCommandType=1
fp_iPageSize=0
fp_fTableFormat=True
fp_fMenuFormat=False
fp_sMenuChoice=""
fp_sMenuValue=""
fp_sColTypes="&Insurance=202&Ins Plan=202&ParticipatingPhysician=202&Effective Date=135&Expiring Date=202&Provider Type=202&Contract Type=202&Field8=202&Plan=202&"
fp_iDisplayCols=9
fp_fCustomQuery=True
BOTID=2
fp_iRegion=BOTID
%>
<!--#include file="_fpclass/fpdbrgn1.inc"-->
<!--webbot bot="DatabaseRegionStart" endspan i-checksum="6956" -->
      <tr>
        <td> <span class="style26">
          <!--webbot bot="DatabaseResultColumn" s-columnnames="Insurance,Ins Plan,ParticipatingPhysician,Effective Date,Expiring Date,Provider Type,Contract Type,Field8,Plan" s-column="Insurance" b-tableformat="TRUE" b-hashtml="FALSE" b-makelink="FALSE" clientside b-MenuFormat preview="<font size="-1"><<</font>Insurance<font size="-1">>></font>" startspan --><%=FP_FieldVal(fp_rs,"Insurance")%><!--webbot bot="DatabaseResultColumn" endspan i-checksum="19581" -->
        </span></td>
        <td> </td>
        <td>
          <!--webbot bot="DatabaseResultColumn" s-columnnames="Insurance,Ins Plan,ParticipatingPhysician,Effective Date,Expiring Date,Provider Type,Contract Type,Field8,Plan" s-column="Ins Plan" b-tableformat="TRUE" b-hashtml="FALSE" b-makelink="FALSE" clientside b-MenuFormat preview="<font size="-1"><<</font>Ins Plan<font size="-1">>></font>" startspan --><%=FP_FieldVal(fp_rs,"Ins Plan")%><!--webbot bot="DatabaseResultColumn" endspan i-checksum="15913" -->
        </td>
        <td> </td>
        <td> <span class="style28">
          <!--webbot bot="DatabaseResultColumn" s-columnnames="Insurance,Ins Plan,ParticipatingPhysician,Effective Date,Expiring Date,Provider Type,Contract Type,Field8,Plan" s-column="ParticipatingPhysician" b-tableformat="TRUE" b-hashtml="FALSE" b-makelink="FALSE" clientside b-MenuFormat preview="<font size="-1"><<</font>ParticipatingPhysician<font size="-1">>></font>" startspan --><%=FP_FieldVal(fp_rs,"ParticipatingPhysician")%><!--webbot bot="DatabaseResultColumn" endspan i-checksum="4469" -->
        </span></td>
        <td> </td>
        <td>
          <!--webbot bot="DatabaseResultColumn" s-columnnames="Insurance,Ins Plan,ParticipatingPhysician,Effective Date,Expiring Date,Provider Type,Contract Type,Field8,Plan" s-column="Effective Date" b-tableformat="TRUE" b-hashtml="FALSE" b-makelink="FALSE" clientside b-MenuFormat preview="<font size="-1"><<</font>Effective Date<font size="-1">>></font>" startspan --><%=FP_FieldVal(fp_rs,"Effective Date")%><!--webbot bot="DatabaseResultColumn" endspan i-checksum="31951" --></td>
        <td> </td>
        <td>
          <!--webbot bot="DatabaseResultColumn" s-columnnames="Insurance,Ins Plan,ParticipatingPhysician,Effective Date,Expiring Date,Provider Type,Contract Type,Field8,Plan" s-column="Expiring Date" b-tableformat="TRUE" b-hashtml="FALSE" b-makelink="FALSE" clientside b-MenuFormat preview="<font size="-1"><<</font>Expiring Date<font size="-1">>></font>" startspan --><%=FP_FieldVal(fp_rs,"Expiring Date")%><!--webbot bot="DatabaseResultColumn" endspan i-checksum="27156" --></td>
        <td> </td>
        <td>
          <!--webbot bot="DatabaseResultColumn" s-columnnames="Insurance,Ins Plan,ParticipatingPhysician,Effective Date,Expiring Date,Provider Type,Contract Type,Field8,Plan" s-column="Provider Type" b-tableformat="TRUE" b-hashtml="FALSE" b-makelink="FALSE" clientside b-MenuFormat preview="<font size="-1"><<</font>Provider Type<font size="-1">>></font>" startspan --><%=FP_FieldVal(fp_rs,"Provider Type")%><!--webbot bot="DatabaseResultColumn" endspan i-checksum="29313" --></td>
        <td> </td>
        <td>
          <!--webbot bot="DatabaseResultColumn" s-columnnames="Insurance,Ins Plan,ParticipatingPhysician,Effective Date,Expiring Date,Provider Type,Contract Type,Field8,Plan" s-column="Contract Type" b-tableformat="TRUE" b-hashtml="FALSE" b-makelink="FALSE" clientside b-MenuFormat preview="<font size="-1"><<</font>Contract Type<font size="-1">>></font>" startspan --><%=FP_FieldVal(fp_rs,"Contract Type")%><!--webbot bot="DatabaseResultColumn" endspan i-checksum="28136" --></td>
      </tr>
      <tr bgcolor="#F9F9F9">
        <td colspan="13"><hr size="1" class="unnamed2">
</td>
      </tr>
      <!--webbot bot="DatabaseRegionEnd" b-tableformat="TRUE" b-menuformat="FALSE" u-dbrgn2="_fpclass/fpdbrgn2.inc" i-groupsize="0" clientside tag="TBODY" preview="<tr><td colspan=64 bgcolor="#FFFF00" align="left" width="100%"><font color="#000000">This is the end of a Database Results region.</font></td></tr>" startspan --><!--#include file="_fpclass/fpdbrgn2.inc"-->
<!--webbot bot="DatabaseRegionEnd" endspan i-checksum="62730" -->
    </tbody>
  </table>
  <p> </p>
  <table width="527" border="0" cellspacing="0" cellpadding="0">
    <tr bgcolor="#F9F9F9">
      <td width="66" bgcolor="#FFFFFF"> </td>
      <td width="468" bgcolor="#F9F9F9" class="style39"><a href="testing_17thjan/index.htm" target="_top">Contact Us</a> | <a href="testing_17thjan/meetphysicians.htm" target="mainFrame">Meet your Physician</a> |<a href="testing_17thjan/handouts.htm"> Patient Handouts</a> | <a href="searchtesting/search.asp" target="_top">Search</a> | <a href="testing_17thjan/employment.htm">Jobs</a> | <a href="testing_17thjan/directions/directions.htm">Directions</a> </td>
    </tr>
  </table>
</div>
<form method="POST" action="test3.asp">
  <table width="793" height="185" border="0">
    <tr>
      <td width="70" height="181"> </td>
      <td width="713"><p><span class="style29 style30"><a href="testing_17thjan/index.htm">Back to testing Page</a></span></p>
        <table width="381" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td width="27"> </td>
            <td width="192"><span class="style36">Physician</span></td>
            <td width="69"><span class="style36">Plan</span></td>
            <td width="93" bgcolor="#FFFFCC"><a href="test3.asp" class="style36 style40" onClick="MM_openBrWindow('http://mycomp/test4.asp','','scrollbars=yes');MM_openBrWindow('http://mycomp/test4.asp','','scrollbars=yes')">Complete List</a> </td>
          </tr>
        </table>
        <!--#include file="_fpclass/fpdblib.inc"-->
          <% if 0 then %>
          <script language="JavaScript">
document.write("<div style='background: yellow; color: black;'>The Database Results component on this page is unable to display database content. The page must have a filename ending in '.asp', and the web must be hosted on a server that supports Active Server Pages.</div>");
            </script>
          <% end if %>
          <%
fp_sQry="SELECT DISTINCT ParticipatingPhysician FROM tabulated where ParticipatingPhysician IS NOT NULL"
fp_sDefault=""
fp_sNoRecords="No records returned."
fp_sDataConn="Sample"
fp_iMaxRecords=256
fp_iCommandType=1
fp_iPageSize=0
fp_fTableFormat=False
fp_fMenuFormat=True
fp_sMenuChoice="ParticipatingPhysician"
fp_sMenuValue="ParticipatingPhysician"
fp_sColTypes="&Insurance=202&Ins Plan=202&ParticipatingPhysician=202&Effective Date=135&Expiring Date=202&Provider Type=202&Contract Type=202&Field8=202&Plan=202&"
fp_iDisplayCols=1
fp_fCustomQuery=False
BOTID=1
fp_iRegion=BOTID
%>
          <!--webbot bot="DatabaseRegionStart" endspan -->   
            <select name="ParticipatingPhysician" size="1" class="style28">
              <option selected value="%">ALL</option>
              <!--webbot bot="AspInclude" clientside u-incfile="_fpclass/fpdbrgn1.inc" startspan -->
              <!--#include file="_fpclass/fpdbrgn1.inc"-->
              <!--webbot bot="AspInclude" endspan i-checksum="26752" -->
              <option><%=FP_FieldHTML(fp_rs,"ParticipatingPhysician")%></option>
              <!--webbot bot="AspInclude" clientside u-incfile="_fpclass/fpdbrgn2.inc" startspan -->
              <!--#include file="_fpclass/fpdbrgn2.inc"-->
              <!--webbot bot="AspInclude" endspan i-checksum="26756" -->
            </select>
          <!--webbot bot="DatabaseRegionEnd" b-tableformat="FALSE" b-menuformat="TRUE" u-dbrgn2="_fpclass/fpdbrgn2.inc" i-groupsize="0" clientside preview=" <span style="color: rgb(0,0,0); background-color: rgb(255,255,0)">Results</span> " startspan --><!--webbot bot="DatabaseRegionEnd" endspan -->
          <!--webbot bot="DatabaseRegionStart" s-columnnames="Insurance,Ins Plan,ParticipatingPhysician,Effective Date,Expiring Date,Provider Type,Contract Type,Field8,Plan" s-columntypes="202,202,202,135,202,202,202,202,202" s-dataconnection="Sample" b-tableformat="FALSE" b-menuformat="TRUE" s-menuchoice="Insurance" s-menuvalue="Insurance" b-tableborder="TRUE" b-tableexpand="TRUE" b-tableheader="TRUE" b-listlabels="TRUE" b-listseparator="TRUE" i-listformat="0" b-makeform="TRUE" s-recordsource="tabulated" s-displaycolumns="Insurance" s-criteria s-order s-sql="SELECT * FROM tabulated" b-procedure="FALSE" clientside suggestedext="asp" s-defaultfields s-norecordsfound="No records returned." i-maxrecords="0" i-groupsize="0" botid="0" u-dblib="_fpclass/fpdblib.inc" u-dbrgn1="_fpclass/fpdbrgn1.inc" u-dbrgn2="_fpclass/fpdbrgn2.inc" preview=" <span style="color: rgb(0,0,0); background-color: rgb(255,255,0)">Database</span> " startspan b-InForm="TRUE" b-WasTableFormat="FALSE" --><!--#include file="_fpclass/fpdblib.inc"-->
<% if 0 then %>
<SCRIPT Language="JavaScript">
document.write("<div style='background: yellow; color: black;'>The Database Results component on this page is unable to display database content. The page must have a filename ending in '.asp', and the web must be hosted on a server that supports Active Server Pages.</div>");
</SCRIPT>
<% end if %>
<%
fp_sQry="SELECT * FROM tabulated"
fp_sDefault=""
fp_sNoRecords="No records returned."
fp_sDataConn="Sample"
fp_iMaxRecords=0
fp_iCommandType=1
fp_iPageSize=0
fp_fTableFormat=False
fp_fMenuFormat=True
fp_sMenuChoice="Insurance"
fp_sMenuValue="Insurance"
fp_sColTypes="&Insurance=202&Ins Plan=202&ParticipatingPhysician=202&Effective Date=135&Expiring Date=202&Provider Type=202&Contract Type=202&Field8=202&Plan=202&"
fp_iDisplayCols=1
fp_fCustomQuery=False
BOTID=0
fp_iRegion=BOTID
%>
<!--webbot bot="DatabaseRegionStart" endspan i-checksum="58921" -->
            <select name="Insurance" size="1" class="style26">
              <option selected value="%">ALL</option>
              <!--webbot bot="AspInclude" clientside u-incfile="_fpclass/fpdbrgn1.inc" startspan -->
              <!--#include file="_fpclass/fpdbrgn1.inc"-->
              <!--webbot bot="AspInclude" endspan i-checksum="26752" -->
              <option><%=FP_FieldHTML(fp_rs,"Insurance")%></option>
              <!--webbot bot="AspInclude" clientside u-incfile="_fpclass/fpdbrgn2.inc" startspan -->
              <!--#include file="_fpclass/fpdbrgn2.inc"-->
              <!--webbot bot="AspInclude" endspan i-checksum="26756" -->
            </select>
          <input name="B1" type="submit" class="style1" value="Submit">
          <!--#include file="_fpclass/fpdblib.inc"-->
          <% if 0 then %>
            <script language="JavaScript">
document.write("<div style='background: yellow; color: black;'>The Database Results component on this page is unable to display database content. The page must have a filename ending in '.asp', and the web must be hosted on a server that supports Active Server Pages.</div>");
            </script>
          <% end if %>
          <%
fp_sQry="SELECT * FROM tabulated"
fp_sDefault=""
fp_sNoRecords="No records returned."
fp_sDataConn="Sample"
fp_iMaxRecords=256
fp_iCommandType=1
fp_iPageSize=0
fp_fTableFormat=False
fp_fMenuFormat=True
fp_sMenuChoice="ParticipatingPhysician"
fp_sMenuValue="ParticipatingPhysician"
fp_sColTypes="&Insurance=202&Ins Plan=202&ParticipatingPhysician=202&Effective Date=135&Expiring Date=202&Provider Type=202&Contract Type=202&Field8=202&Plan=202&"
fp_iDisplayCols=1
fp_fCustomQuery=False
BOTID=1
fp_iRegion=BOTID
%>
 </b> </p>        <p>                    <span class="style35"> Please scroll down to see your search results</span></p>
      </td>
    </tr>
  </table>
</form>
<p> </p>
<p> </p>
<p> </p>
<p align="left" class="style34"> </p>
<p class="style34"> </p>
<p class="style34"> </p>
<div id="Layer3" style="position:absolute; width:167px; height:256px; z-index:3; left: 604px; top: 0px;"><span class="style1"><img src="http://mycomp/testing_17thjan/images/clickbelow.jpg" width="162" height="30"><br>
  <br>
  <a href="searchtesting/largefont.asp" class="style1" onMouseOver="MM_swapImage('Image4','','http://mycomp/testing_17thjan/images/mlargefont.jpg',1)" onMouseOut="MM_swapImgRestore()"><img src="http://mycomp/testing_17thjan/images/largefont.jpg" name="Image4" width="156" height="37" border="0" id="Image4"><br>
  <br>
  <span class="style34"><a href="/test3.asp" onMouseOver="MM_swapImage('Image3','','http://mycomp/testing_17thjan/images/mphysicians.jpg',1)" onMouseOut="MM_swapImgRestore()"><img src="http://mycomp/testing_17thjan/images/physicians.jpg" name="Image3" width="158" height="45" border="0" id="Image3"></a></span>  <br>
    <br>
  </a></span><span class="style34"><a href="searchtesting/largefont.asp" class="style1" onMouseOver="MM_swapImage('Image4','','http://mycomp/testing_17thjan/images/mlargefont.jpg',1)" onMouseOut="MM_swapImgRestore()"><a href="/test3.asp" onMouseOver="MM_swapImage('Image3','','http://mycomp/testing_17thjan/images/mphysicians.jpg',1)" onMouseOut="MM_swapImgRestore()"><span class="style1"><a href="searchtesting/search.asp" onMouseOver="MM_swapImage('Image2','','http://mycomp/testing_17thjan/images/msmallfont.jpg',1)" onMouseOut="MM_swapImgRestore()">
    <img src="http://mycomp/testing_17thjan/images/smallfont.jpg" name="Image2" width="147" height="30" border="0" id="Image2"><br>
  <br>
</a><a href="searchtesting/search.asp" onMouseOver="MM_swapImage('Image1','','http://mycomp/testing_17thjan/images/mkeyword.jpg',1)" onMouseOut="MM_swapImgRestore()"><img src="http://mycomp/testing_17thjan/images/keyword.jpg" name="Image1" width="143" height="58" border="0" id="Image1"></a></span></div>
<p class="style34"> </p>
<p class="style34"> </p>
<p> </p>
<p> </p>

(in reply to Spooky)
prasmile2002

 

Posts: 33
Joined: 2/14/2005
Status: offline

 
RE: List boxes Display ALL - 2/14/2005 18:42:41   
Hi,

I posted my code in my previous post..inshort I want to be able to display all records from both the lists when I pull ALL from both the lists..That's what I am not able to accomplish..

Thanks
Raj

(in reply to Spooky)
dzirkelb1

 

Posts: 1315
Joined: 10/5/2004
From: Cedar Rapids, Iowa
Status: offline

 
RE: List boxes Display ALL - 2/15/2005 10:09:19   
<option value="">All</option>

give that a whirl

(in reply to prasmile2002)
prasmile2002

 

Posts: 33
Joined: 2/14/2005
Status: offline

 
RE: List boxes Display ALL - 2/15/2005 11:51:57   
Hi..
Thanks for that but I am able to get the results even when I use the "%" sign..ofcourse I tried yours and it works too..Thanks for that..that's new for me..

But my question is...I want to select(ALL) in both the list boxes and be able to pull all the records..Which now I am unable to..

Also I want to be able to be there on that selection..I am reverting to ALL every time the data is displayed..for eg: If I pull ALL and then select a value from the list 2..The data is displayed but both the list boxes are reverting to "ALL". I tried removing the "Selected" but it doesn't let me stay on the selected lists..

Thanks
Raj

(in reply to dzirkelb1)
dzirkelb1

 

Posts: 1315
Joined: 10/5/2004
From: Cedar Rapids, Iowa
Status: offline

 
RE: List boxes Display ALL - 2/15/2005 12:13:07   
You need to have an <option></option> at the beginning of your select to display nothing...then, it passes nothing to the next page.

Can you post your code for the sql statement and your option html code?

(in reply to prasmile2002)
prasmile2002

 

Posts: 33
Joined: 2/14/2005
Status: offline

 
RE: List boxes Display ALL - 2/15/2005 12:45:09   
I sent my code via e mail..

(in reply to dzirkelb1)
dzirkelb1

 

Posts: 1315
Joined: 10/5/2004
From: Cedar Rapids, Iowa
Status: offline

 
RE: List boxes Display ALL - 2/15/2005 13:57:45   
hahaah, my bad, i replied with a out of the norm email on that...I thought you sent me an email for something else :)

I'll take a look at it in a bit..sorry for the confusing email :)

(in reply to prasmile2002)
dzirkelb1

 

Posts: 1315
Joined: 10/5/2004
From: Cedar Rapids, Iowa
Status: offline

 
RE: List boxes Display ALL - 2/15/2005 14:30:19   
First, I'd put this on a diet if you can...it makes it easier to modify.

Try changing to this:

<option value="">ALL</option>
<option><%=FP_FieldHTML(fp_rs,"ParticipatingPhysiciain")%></option>

That is what should show for you options...same for the other one.

Now, on your sql that displays the data, change the code to this:

SELECT * FROM tabulated WHERE IIf(('::Insurance::'&''=''), True, Insurance='::Insurance::') AND IIf (('::ParticipatingPhysician::'&''=''), True, ParticipatingPhysician='::ParticipatingPhysician::')

Change that on the drw and it should work out for ya.

I would recommend doing these changes on a seperate page, however, so what you currently have doens't get lost if this doesn't work.

(in reply to dzirkelb1)
prasmile2002

 

Posts: 33
Joined: 2/14/2005
Status: offline

 
RE: List boxes Display ALL - 2/15/2005 14:44:51   
Thanks a lot..works grreat.. I want to be able to store the values selected to stay on the list..Works great when you pull the list..doesn't work for all..Also the default list is empty

Reply at your convenience..I looked at your code(SQL)..realized what I should be doing..

Thanks any ways
best regards
Raj

(in reply to dzirkelb1)
dzirkelb1

 

Posts: 1315
Joined: 10/5/2004
From: Cedar Rapids, Iowa
Status: offline

 
RE: List boxes Display ALL - 2/15/2005 15:17:02   
What doe sit do when you select ALL? And, what do you mean by the default list is empty? Do you want it to have a blank option as the default?

(in reply to prasmile2002)
prasmile2002

 

Posts: 33
Joined: 2/14/2005
Status: offline

 
RE: List boxes Display ALL - 2/15/2005 15:23:58   
It pulls all the records but both the list boxes are empty..
But when I pull some values in the list boxes..it holds those values..I wouldn't want the list boxes to be empty..
may be because of the <option value=" "> ALL</option>

Thanks
Raj

(in reply to dzirkelb1)
dzirkelb1

 

Posts: 1315
Joined: 10/5/2004
From: Cedar Rapids, Iowa
Status: offline

 
RE: List boxes Display ALL - 2/15/2005 15:28:13   
On the drw, give the results a default value of something that would never happen...meaning, for your insurance field, give it a default value of something like kskariuadf...that will force it to produce "no records returned" on the load of the page. Then, when the person searches for insurance or the other field, it will only display what is searched for.

Is that what you are looking for?

Also, is this site up somewhere to look at? Might help to see it in action.

(in reply to prasmile2002)
prasmile2002

 

Posts: 33
Joined: 2/14/2005
Status: offline

 
RE: List boxes Display ALL - 2/15/2005 15:44:34   
The site is not up..I am still working on these minute details..I am testing it on my local machine..
Also do you mean to set it to default.like this

<option selected value="<%=Request("ParticipatingPhysician")%>"><%=Request("ParticipatingPhysician")%>
</option>

I coded it that way so that when someone selects some value..it is retained even after the values are popluated..

What happens is: When the page opens up..it pulls up all the records..But both the lists are empty..

And when I pull "ALL" from both the lists, the records are displayed but the lists are empty again....But when I pull either the Physicians name or Insurance from both the lists..They have those values that the user selects in the List boxes..which is what I wanted..But I also wanted "ALL" to be displayed when I select ALL in both the lists..


Thanks
Raj

(in reply to dzirkelb1)
dzirkelb1

 

Posts: 1315
Joined: 10/5/2004
From: Cedar Rapids, Iowa
Status: offline

 
RE: List boxes Display ALL - 2/15/2005 16:25:25   
Guess I'm out of ideas here... I know how to do everything you wish to accomplish, I just can't get them all to work together.

If you choose to not show any results when opening the page, then place a default on step 3 of the drw to something that will never be searched by. This works fine.

The displaying all records then doesn't work if you have a default on a field that isn't searched by...so, there is a contradiction.

I don't know how to keep the value shown in the list box once a selection is made.

This may require some extra coding; however, the page must be on a diet for it to work...can you place it on a diet?

(in reply to prasmile2002)
prasmile2002

 

Posts: 33
Joined: 2/14/2005
Status: offline

 
RE: List boxes Display ALL - 2/15/2005 16:45:13   
Thanks so much for your help...I will try to look into it..

(in reply to dzirkelb1)
Page:   [1]

All Forums >> Web Development >> ASP and Database >> List boxes Display ALL
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts