asp.net - dynamic url where text box data changes url -


here have. sharepoint page has textbox , search button. textbox data tied of tables , fills them in according company code typed textbox.

i'm trying add url take user out new page see sharepoint list filtered on company code entered in original textbox.

so far can make url go whatever company choose hardcoding url this:

http://mysite/lists/call%20log/company%20by%20category.aspx?view={7c16bc72-8f1a-457a-9908-af9e66de97dc}&filterfield1=linktitle&filtervalue1=abccompany 

for whatever reason unable or can't figure out how set filtervalue1 = <<text textbox>>.

here sample of code:

<webpartpages:spproxywebpartmanager runat="server" id="proxywebpartmanager"> </webpartpages:spproxywebpartmanager> enter co id , click &quot;search&quot;&nbsp; <asp:textbox runat="server" id="tb_coid" width="83px"></asp:textbox> &nbsp; <asp:button runat="server" text="search" id="button1"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <a target="_blank" href="http://site/lists/call%20log/company%20by%20category.aspx?view={7c16bc72-8f1a-457a-9908-af9e66de97dc}&amp;filterfield1=linktitle&amp;filtervalue1=<<text textbox here>>"> click here </a>to view call logs 

in case anyeone else looking answer question figured out.

<script type="text/javascript"> function showreport() { var coid = document.getelementbyid('ctl00_placeholdermain_tb_coid').value; window.open("http://site/lists/call%20log/company%20by%20category.aspx?view=     {7c16bc72-8f1a-457a-9908-af9e66de97dc}&amp;filterfield1=linktitle&amp;filtervalue1=" +     coid, "_blank"); } </script>     <webpartpages:spproxywebpartmanager runat="server" id="proxywebpartmanager">     </webpartpages:spproxywebpartmanager>enter co id , click     &quot;search&quot;&nbsp;     <asp:textbox runat="server" id="tb_coid" width="83px"></asp:textbox>     &nbsp;     <asp:button runat="server" text="search" id="button1"/>&nbsp;&nbsp;&nbsp;&    nbsp;&nbsp;     <a href="javascript:void(0);" onclick="showreport();">click here</a> view     call logs related company<br>     <br> 

i had add these lines of code top of page , works amazingly


Comments

Popular posts from this blog

ios - UICollectionView Self Sizing Cells with Auto Layout -

node.js - ldapjs - write after end error -

DOM Manipulation in Wordpress (and elsewhere) using php -