Solved

How to create a product form with multiple conditions?

Posted on 2001-08-11
19
245 Views
Last Modified: 2013-12-24
Okay using FP 2000, Access 2000 and FPSE as the platform I have created this ASP page as a basic structure of what I am looking for.

It contains the portion of the question also so that it will be easier to go back and forth between here and the asp page.

The <<quantity>> [single line box] and the <<FCU>> [Radio button] (unselected) but when selected its a value of Yes.

Those two entries are what needs to be changed by the form for each line item, I put each item with its ID(Primary Key) in one table so it can be changed I think by it. Here is the catch, there are 35 office locations and this is just merely a test object, I am familiar with ASP, FP and Access but far from being a guru...

 If i am totally wrong in my theory of this or if its not able to be done due to web limitations.  Also this will be done monthly, and I would like for it to store the changes by the office location.

BTW Hi CLassy Links, how you doing today :)

here is the link for the .asp page

http://www.nu-wave.com/jw/sample.asp


newwavepro
0
Comment
Question by:newwavepro
  • 10
  • 9
19 Comments
 
LVL 7

Expert Comment

by:ClassyLinks
ID: 6377056
Hi newwavepro!  I'm fine thx.

First...please tell me you are coding this yourself & not using an FP component  ;-)

Next post your ASP code here (naturally I cannot see it in the browser) so I can see how far you are already with the coding.

What you are asking should be no prob....with a little work.

Cheers!
0
 
LVL 2

Author Comment

by:newwavepro
ID: 6377319
well i have just used the FP database results to get what I have so far, I am not that strong in ASP, you should be able to save file as and get the entire code, I think.

<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title>This is the Sample item list</title>
</head>

<body stylesrc="../Default.htm" style="font-family: Tahoma; font-size: 10pt; font-weight: bold">

<form method="POST" action="--WEBBOT-SELF--" onsubmit="return FrontPage_Form1_Validator(this)" name="FrontPage_Form1">
  <!--webbot bot="SaveResults" startspan U-File="../_private/form_results.txt"
  S-Format="TEXT/CSV" S-Label-Fields="TRUE" --><input TYPE="hidden" NAME="VTI-GROUP" VALUE="0"><!--webbot
  bot="SaveResults" endspan -->
  <p><!--webbot bot="Validation" S-Display-Name="Must Select One Location"
  B-Value-Required="TRUE" --><select size="1" name="D1">
    <option>Home Office</option>
    <option>Office 2</option>
    <option>Office 3</option>
    <option>Office 4</option>
    <option>Office 5</option>
  </select> <input type="submit" value="Submit" name="B1"><input type="reset" value="Reset" name="B2"></p>
</form>

<p>&nbsp;</p>
<table width="100%" border="1">
  <thead>
    <tr>
      <td><b><font size="2">ID</font></b></td>
      <td><b><font size="2">Quantity</font></b></td>
      <td><b><font size="2">Item No</font></b></td>
      <td><b><font size="2">Symbol</font></b></td>
      <td><b><font size="2">For Construction Use</font></b></td>
    </tr>
  </thead>
  <tbody>
    <!--webbot bot="DatabaseRegionStart" startspan
    s-columnnames="ID,Quantity,Item No,Description,Symbol,For Cong Use"
    s-columntypes="3,3,3,202,202,202" s-dataconnection="literature"
    b-tableformat="TRUE" b-menuformat="FALSE" s-menuchoice="ID" s-menuvalue="ID"
    b-tableborder="TRUE" b-tableexpand="TRUE" b-tableheader="TRUE"
    b-listlabels="TRUE" b-listseparator="TRUE" i-ListFormat="0"
    b-makeform="TRUE" s-recordsource="S14E"
    s-displaycolumns="ID,Quantity,Item No,Symbol,For Cong Use" s-criteria
    s-order s-sql="SELECT * FROM S14E" b-procedure="FALSE" clientside
    SuggestedExt="asp" s-DefaultFields s-NoRecordsFound="No records returned."
    i-MaxRecords="256" i-GroupSize="30" BOTID="0"
    u-dblib="../_fpclass/fpdblib.inc" u-dbrgn1="../_fpclass/fpdbrgn1.inc"
    u-dbrgn2="../_fpclass/fpdbrgn2.inc" tag="TBODY"
    local_preview="&lt;tr&gt;&lt;td colspan=64 bgcolor=&quot;#FFFF00&quot; align=&quot;left&quot; width=&quot;100%&quot;&gt;&lt;font color=&quot;#000000&quot;&gt;Database Results regions will not preview unless this page is fetched from a Web server with a web browser. The following table row will repeat once for every record returned by the query.&lt;/font&gt;&lt;/td&gt;&lt;/tr&gt;"
    preview="<tr><td colspan=64 bgcolor=&quot;#FFFF00&quot; align=&quot;left&quot; width=&quot;100%&quot;><font color=&quot;#000000&quot;>This is the start of a Database Results region.</font></td></tr>" b-WasTableFormat="TRUE" --><!--#include file="../_fpclass/fpdblib.inc"-->
--------
Selection of Data from Access Table is here
--------
<%
fp_sQry="SELECT * FROM S14E"
fp_sDefault=""
fp_sNoRecords="<tr><td colspan=5 align=left width=""100%"">No records returned.</td></tr>"
fp_sDataConn="literature"
fp_iMaxRecords=256
fp_iCommandType=1
fp_iPageSize=30
fp_fTableFormat=True
fp_fMenuFormat=False
fp_sMenuChoice="ID"
fp_sMenuValue="ID"
fp_iDisplayCols=5
fp_fCustomQuery=False
BOTID=0
fp_iRegion=BOTID
%>
<!--#include file="../_fpclass/fpdbrgn1.inc"-->
<!--webbot bot="DatabaseRegionStart" i-CheckSum="45851" endspan -->
    <tr>
      <td><font size="2"><!--webbot bot="DatabaseResultColumn" startspan
        s-columnnames="ID,Quantity,Item No,Description,Symbol,For Cong Use"
        s-column="ID" b-tableformat="TRUE" b-hasHTML="FALSE" clientside
        local_preview="&lt;font size=&quot;-1&quot;&gt;&amp;lt;&amp;lt;&lt;/font&gt;ID&lt;font size=&quot;-1&quot;&gt;&amp;gt;&amp;gt;&lt;/font&gt;"
        preview="&lt;font size=&quot;-1&quot;&gt;&amp;lt;&amp;lt;&lt;/font&gt;ID&lt;font size=&quot;-1&quot;&gt;&amp;gt;&amp;gt;&lt;/font&gt;" --><%=FP_FieldVal(fp_rs,"ID")%><!--webbot
        bot="DatabaseResultColumn" i-CheckSum="62813" endspan -->
        </font></td>
      <td><font size="2"><!--webbot bot="DatabaseResultColumn" startspan
        s-columnnames="ID,Quantity,Item No,Description,Symbol,For Cong Use"
        s-column="Quantity" b-tableformat="TRUE" b-hasHTML="FALSE" clientside
        local_preview="&lt;font size=&quot;-1&quot;&gt;&amp;lt;&amp;lt;&lt;/font&gt;Quantity&lt;font size=&quot;-1&quot;&gt;&amp;gt;&amp;gt;&lt;/font&gt;"
        preview="&lt;font size=&quot;-1&quot;&gt;&amp;lt;&amp;lt;&lt;/font&gt;Quantity&lt;font size=&quot;-1&quot;&gt;&amp;gt;&amp;gt;&lt;/font&gt;" --><%=FP_FieldVal(fp_rs,"Quantity")%><!--webbot
        bot="DatabaseResultColumn" i-CheckSum="18235" endspan -->
        </font></td>
      <td><font size="2"><!--webbot bot="DatabaseResultColumn" startspan
        s-columnnames="ID,Quantity,Item No,Description,Symbol,For Cong Use"
        s-column="Item No" b-tableformat="TRUE" b-hasHTML="FALSE" clientside
        local_preview="&lt;font size=&quot;-1&quot;&gt;&amp;lt;&amp;lt;&lt;/font&gt;Item No&lt;font size=&quot;-1&quot;&gt;&amp;gt;&amp;gt;&lt;/font&gt;"
        preview="&lt;font size=&quot;-1&quot;&gt;&amp;lt;&amp;lt;&lt;/font&gt;Item No&lt;font size=&quot;-1&quot;&gt;&amp;gt;&amp;gt;&lt;/font&gt;" --><%=FP_FieldVal(fp_rs,"Item No")%><!--webbot
        bot="DatabaseResultColumn" i-CheckSum="14018" endspan -->
        </font></td>
      <td><font size="2"><!--webbot bot="DatabaseResultColumn" startspan
        s-columnnames="ID,Quantity,Item No,Description,Symbol,For Cong Use"
        s-column="Symbol" b-tableformat="TRUE" b-hasHTML="FALSE" clientside
        local_preview="&lt;font size=&quot;-1&quot;&gt;&amp;lt;&amp;lt;&lt;/font&gt;Symbol&lt;font size=&quot;-1&quot;&gt;&amp;gt;&amp;gt;&lt;/font&gt;"
        preview="&lt;font size=&quot;-1&quot;&gt;&amp;lt;&amp;lt;&lt;/font&gt;Symbol&lt;font size=&quot;-1&quot;&gt;&amp;gt;&amp;gt;&lt;/font&gt;" --><%=FP_FieldVal(fp_rs,"Symbol")%><!--webbot
        bot="DatabaseResultColumn" i-CheckSum="17714" endspan -->
        </font></td>
      <td><font size="2"><!--webbot bot="DatabaseResultColumn" startspan
        s-columnnames="ID,Quantity,Item No,Description,Symbol,For Cong Use"
        s-column="For Cong Use" b-tableformat="TRUE" b-hasHTML="FALSE"
        clientside
        local_preview="&lt;font size=&quot;-1&quot;&gt;&amp;lt;&amp;lt;&lt;/font&gt;For Cong Use&lt;font size=&quot;-1&quot;&gt;&amp;gt;&amp;gt;&lt;/font&gt;"
        preview="&lt;font size=&quot;-1&quot;&gt;&amp;lt;&amp;lt;&lt;/font&gt;For Cong Use&lt;font size=&quot;-1&quot;&gt;&amp;gt;&amp;gt;&lt;/font&gt;" --><%=FP_FieldVal(fp_rs,"For Cong Use")%><!--webbot
        bot="DatabaseResultColumn" i-CheckSum="24504" endspan -->
        </font></td>
    </tr>
    <!--webbot bot="DatabaseRegionEnd" startspan b-tableformat="TRUE"
    b-menuformat="FALSE" u-dbrgn2="../_fpclass/fpdbrgn2.inc" i-groupsize="30"
    clientside tag="TBODY"
    local_preview="<tr><td colspan=64 bgcolor=&quot;#FFFF00&quot; align=&quot;left&quot; width=&quot;100%&quot;><font color=&quot;#000000&quot;>This is the end of a Database Results region.</font></td></tr><TR><TD ALIGN=LEFT VALIGN=MIDDLE COLSPAN=64><FORM><NOBR><INPUT TYPE=Button VALUE=&quot;  |<  &quot;><INPUT TYPE=Button VALUE=&quot;   <  &quot;><INPUT TYPE=Button VALUE=&quot;  >   &quot;><INPUT TYPE=Button VALUE=&quot;  >|  &quot;>  [1/30]</NOBR></FORM></td></tr>"
    preview="<tr><td colspan=64 bgcolor=&quot;#FFFF00&quot; align=&quot;left&quot; width=&quot;100%&quot;><font color=&quot;#000000&quot;>This is the end of a Database Results region.</font></td></tr><TR><TD ALIGN=LEFT VALIGN=MIDDLE COLSPAN=64><NOBR><INPUT TYPE=Button VALUE=&quot;  |<  &quot;><INPUT TYPE=Button VALUE=&quot;   <  &quot;><INPUT TYPE=Button VALUE=&quot;  >   &quot;><INPUT TYPE=Button VALUE=&quot;  >|  &quot;>  [1/30]</NOBR><BR></td></tr>" --><!--#include file="../_fpclass/fpdbrgn2.inc"-->
<!--webbot bot="DatabaseRegionEnd" i-CheckSum="56926" endspan -->
  </tbody>
</table>

</body>

</html>


0
 
LVL 7

Expert Comment

by:ClassyLinks
ID: 6377797
UGLY!

You're not going to be able to accomplish what you want to do by using the db results wizard.  You are going to have to switch to "manual" asp....DIY ;-)


We are going to need to employ some JavaScript to do the jumping based on the drop down...that is pretty standard.

The way I would do it (if I understand your question correctly) is to build a page that initially displays the data for the Home Office....whenever that is changed (ie Office2, 3 or 4 is chosen) the page will submit to itself with a variable telling it which office to display next.


To do this, we need to create the database connection manually.....so here is what I will need from you....

The name of your access database, it's position on the server relative to the page and the field names/types.  (or just email me the db at eeHelp@classylinks.ca and tell me it's location relative to the page)

What you are asking to do shouldn't be that difficult.
0
 
LVL 2

Author Comment

by:newwavepro
ID: 6377999
I know, I as I said am not versed in ASP but can type just as good as anyone.

>>The way I would do it (if I understand your question correctly) is to build a page that initially displays
the data for the Home Office....whenever that is changed (ie Office2, 3 or 4 is chosen) the page will
submit to itself with a variable telling it which office to display next.

Correct, but this will be a template page the same blank table called S14E the internal office form name but when it is submitted it is sent to the different table (S14EHO, S14EOff2) based on the drop down, if that will work or will I have to create a seperate page for each, I am really trying to keep it as simple as possible. Since I am going to show someone how it works afterwards.

Also one question: Let say the office already submitted an order, how will this know if there is data already in the table or other than 0 for example the 5525 has 10 ordered? how can we post a warning to check for this?
0
 
LVL 7

Expert Comment

by:ClassyLinks
ID: 6378038
No problem...we can create a dynamic select statement telling it which table to choose from.

If somebody already ordered an item you want a warning to pop up if they try to order it again?  Shouldn't be a problem....let me think about it.
0
 
LVL 7

Expert Comment

by:ClassyLinks
ID: 6378366
Ok...here's a start.

Here is your page with a non-FP database connection, a jump menu which displays the content of different tables depending on what you choose.

Now we need to know...where you want the quantity to be able to be changed, what table the changes are to be saved too and what the radio button is for.

<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title>This is the Sample item list</title>
<SCRIPT language = "JavaScript">
<!--
// Array Function
function makeArray() {
var args = makeArray.arguments;
    for (var i = 0; i < args.length; i++) {
    this[i] = args[i];
    }
this.length = args.length;
}
// This array holds the descriptions and names of the pages.
var pages = new makeArray("Select an Office",
                                            "Home Office",
                          "Office 2",
                          "Office 3",
                          "Office 4",
                          "Office 5");
// This array hold the URLs of the pages.
var urls = new makeArray("",
                                           "sample.asp?office=home",
                         "sample.asp?office=2",
                         "sample.asp?office=3",
                         "sample.asp?office=4",
                         "sample.asp?office=5");
// This function determines which page is selected and goes to it.
function goPage(form) {
i = form.menu.selectedIndex;            
    if (i != 0) {
    window.location.href = urls[i];  
    }
}
//-->
</SCRIPT>
</head>

<body stylesrc="http://www.nu-wave.com/Default.htm" style="font-family: Tahoma; font-size: 10pt; font-weight: bold">

<p>&nbsp;</p>
<p>This is the Sample item list, I would like to create a form that controls
each line item that allows the &lt;&lt;Quantity&gt;&gt; to be added to and have
it stored to a table, but here is the catch, I need it to be able to accept it
to the drop down box which contains the location (blank asp page of the table
for that location) The results are to be stored in a &quot;temporary second
table&quot; .&nbsp; Then with each location held&nbsp; I am able to add together
all the tables into one master table. This occurs each month..&nbsp; The only
modification they are allowed to do is in the &lt;&lt;Quantity&gt;&gt; the
quantity will always show up 0 and &lt;&lt;For Construction Use&gt;&gt; the For
Construction Use is to be a Radio button only with it not being selected but
when used attached to Yes value.</p>
<p>This is for an Internet Web Database using FP2000, Access2000 and FPSE</p>
<p>&nbsp;</p>
<SCRIPT language = "JavaScript">
<!--
// The select menu will be displayed wherever you place this code.
document.write('<FORM><SELECT NAME = "menu" onChange = "goPage(this.form)">');
    for (var i = 0; i < pages.length; i++) {
    document.write('<OPTION>' + pages[i]);
    }
document.write('</SELECT></FORM>');
//-->
</SCRIPT>
<%            'connect to your database
            set conn = server.createobject("adodb.connection")
            conn.ConnectionString="Driver={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath("../fpdb/order.mdb")&";"
            conn.open
            
            'Find out what data to display:
            Select Case Request.QueryString("office")
            Case "home"
                        
      'tell the script which table to choose
                  sql="SELECT * FROM S14EHO"
                  set rs=conn.execute(sql)

            'Find out what data to display:
            Case "2"
                        
      'tell the script which table to choose
                  sql="SELECT * FROM S14EOff2"
                  set rs=conn.execute(sql)

            'Find out what data to display:
            Case "3"
                        
      'tell the script which table to choose
                  sql="SELECT * FROM S14EOff3"
                  set rs=conn.execute(sql)

            'Find out what data to display:
            Case "4"
                        
      'tell the script which table to choose
                  sql="SELECT * FROM S14EOff4"
                  set rs=conn.execute(sql)

            'Find out what data to display:
            Case "5"
                        
      'tell the script which table to choose
                  sql="SELECT * FROM S14EOff5"
                  set rs=conn.execute(sql)

            'Find out what data to display:
            Case ""
                        
      'tell the script which table to choose
                  sql="SELECT * FROM S14E"
                  set rs=conn.execute(sql)


%>
<p>&nbsp;</p>
<table width="100%" border="1">
  <thead>
    <tr>
      <td><b><font size="2">ID</font></b></td>
      <td><b><font size="2">Quantity</font></b></td>
      <td><b><font size="2">Item No</font></b></td>
      <td><b><font size="2">Symbol</font></b></td>
      <td><b><font size="2">For Construction Use</font></b></td>
    </tr>
  </thead>
  <tbody><%Do While Not RS.eof%>
    <tr>
      <td><b><font size="2"><%=RS("ID")%></font></b></td>
      <td><b><font size="2"><%=RS("Quantity")%></font></b></td>
      <td><b><font size="2"><%=RS("Item No")%></font></b></td>
      <td><b><font size="2"><%=RS("Symbol")%></font></b></td>
      <td><b><font size="2"><%=RS("For Con Use")%></font></b></td>
    </tr><%RS.MoveNext
    Loop%>
  </tbody>
</table>
<%End Select
rs.close
set rs=nothing
conn.close
set conn = nothing
%>

</body>

</html>
0
 
LVL 2

Author Comment

by:newwavepro
ID: 6378543
Okay Classy: I have posted the Code you have sent and this is where we are at.  
----
Now we need to know...

where you want the quantity to be able to be changed,
>> Within the table so that the supervisor can see the item no and the symbol that goes with each.

what table the changes are to be saved to.
>> The page they will always get is the S14E blank when they first arrive. Thats correct... So the S14E is the template every office gets the same list...The table the data is saved to is according to the drop down box when the submit button is pressed.  It does not go to a seperate page via URL, just a seperate table location in the order.mdb.

So for example I am entering on the blank S14E form, then I am finished I select the location ex(office3), enter the order # and press submit.  So when I submit it goes to S14EOff3 table in the order.mdb file.

and what the radio button is for.
>> This determines if the item ordered is for internal office use or in the field.  Its about a 50/50 split so it is manditory this function is there since they track how the items are used.

-------
Looks great so far, nice connection routine, never knew it was that easy otherwise I would have used it instead of that darn wizard :(

Hope this makes it clearer.
newwavepro

0
 
LVL 7

Expert Comment

by:ClassyLinks
ID: 6379553
Ok...so I've got it a little backwards.....what you want is actually easier  ;-)

To summarize...everyone enters the new amounts on the same table....it just SAVES to a different location depending on the office.  Cool!

See how I always make things more complex than they really are?

Ok....I'll do some switching around.

Any questions so far on the script though?  Do you understand what it is doing?
0
 
LVL 2

Author Comment

by:newwavepro
ID: 6380767
I understand the script is pretty easy now that i look at it a little more closely, but i am not a 'hardcore' programmer, more a hardware and fix the OS person since that all i seem to have time for anymore
0
Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

 
LVL 7

Expert Comment

by:ClassyLinks
ID: 6380808
Ok...I'm almost done over here...just one little glitch I'm making a work around for.
0
 
LVL 7

Expert Comment

by:ClassyLinks
ID: 6386202
Ok..this should do it.  The only thing it doesn't do is autoreset itself on a specific day.  Not sure how I would do that, yet!

<%            'connect to your database
            set conn = server.createobject("adodb.connection")
            conn.ConnectionString="Driver={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath("../fpdb/order.mdb")&";"
            conn.open
            
            'Find out what data to display:
            'office = request.form("office")
      
      'tell the script which table to choose
            
            IF request.form("office")= "Home" then
            selecttable = "S14EHO"
            End If
            IF request.form("office")= "2" then
            selecttable = "S14EOff2"
            End If
            IF request.form("office")= "3" then
            selecttable = "S14EOff3"
            End If
            IF request.form("office")= "4" then
            selecttable = "S14EOff4"
            End If
            IF request.form("office")= "5" then
            selecttable = "S14OEff5"
            End If
            IF request.form("office")= "" then
            selecttable = "S14E"
            End If
      Dim FormElement                  

      Select Case request.querystring("action")
      Case "order"
                  
                  For Each FormElement in Request.Form
                  if Left(FormElement,6)="ItemNo" then
                itemNo=mid(FormElement,7)
                'itemNo=Request.Form(FormElement)
                
             ORDERsql="UPDATE "&selecttable&" SET "
             ORDERsql= ORDERsql& "Quantity = " & request.form("Quantity"&itemNo) & ","
             ORDERsql= ORDERsql& " For_Con_Use = '" & request.form("Con"&itemNo) & "'"
             ORDERsql= ORDERsql& " WHERE Item_No = "&itemNo&""
          conn.execute(ORDERsql)
                     End if
                  Next%>
      <p>Your order has been submitted!</p>

                  
<%      Case "save"%>

                  <form method="post" action="sample.asp?action=order">
                  <%For Each FormElement in Request.Form
                if Left(FormElement,6)="ItemNo" then
                itemNo=Request.Form(FormElement)
                sql="SELECT * FROM " & selecttable & " WHERE Item_No = " &itemNo &""
          'response.write sql
             set rs=conn.execute(sql)
                   If rs("Quantity") >< request.form("Quantity"&itemNo) AND request.form("Quantity"&itemNo) > 0 then%>
                   <p><%=rs("Quantity")%>&nbsp; of Item #<%=rs("Item_No")%>&nbsp; have already been ordered</p>
                        <%End If%>
                  <input type="hidden" name="Quantity<%=rs("Item_No")%>" value="<%=request.form("Quantity"&itemNo)%>">
                  <input type="hidden" name="ItemNo<%=rs("Item_No")%>" value="<%=request.form("Item_No" &itemNo )%>">
                  <input type="hidden" name="Con<%=rs("Item_No")%>" value="<%=request.form("Con"&itemNo)%>">
                  <%End If
                  NEXT%>
                  <input type="hidden" name="office" value="<%=request.form("office")%>">
                  <input type="submit" value="Proceed with Order & Override Existing Values?" name="Proceed"></form>
      <%Case ""
                  sql="SELECT * FROM "&selecttable&""
                  set rs=conn.execute(sql)
      %>
<form method="post" action="sample.asp?action=save">
 
<p><select size="1" name="office">
  <option value="Home">Home Office</option>
  <option value="2">Office2</option>
  <option value="3">Office3</option>
  <option value="4">Office4</option>
  <option value="5">Office5</option>
  </select></p>
<table width="100%" border="1">
  <thead>
    <tr>
      <td><b><font size="2">ID</font></b></td>
      <td><b><font size="2">Quantity</font></b></td>
      <td><b><font size="2">Item No</font></b></td>
      <td><b><font size="2">Symbol</font></b></td>
      <td><b><font size="2">For Construction Use</font></b></td>
    </tr>
  </thead>
  <tbody><%Do While Not RS.eof%>
    <tr>
      <td><b><font size="2"><%=RS("ID")%></font></b></td>
      <td><b><font size="2"><input type="text" size="4" value="0" name="Quantity<%=rs("Item_No")%>"></font></b></td>
      <td><b><font size="2"><%=RS("Item_No")%><input type="hidden" name="ItemNo<%=rs("Item_No")%>" value="<%=RS("Item_No")%>"></font></b></td>
      <td><b><font size="2"><%=RS("Symbol")%></font></b></td>
      <td><b><font size="2"><input type="radio" name="Con<%=rs("Item_No")%>" selected="no" value="Yes"><%=RS("For_Con_Use")%></font></b></td>
    </tr><%RS.MoveNext
    Loop%>
  </tbody>
</table><input type="submit" value="Submit" name="B1"><input type="reset" value="Reset" name="B2"></form>
<%
rs.close
set rs=nothing
End Select
conn.close
set conn = nothing
%>
0
 
LVL 2

Author Comment

by:newwavepro
ID: 6386717
Okay I got the files but I was unable to upload the _vti_cnf folders at any point is this normal? what are they I have not seen them before.

its giving me a couple strange errors as well

This is after you press the proceed with order and override existing values
----
Microsoft OLE DB Provider for ODBC Drivers error '80004005'

[Microsoft][ODBC Microsoft Access Driver] Operation must use an updateable query.

Looks great just a couple minor bugs now that i have it posted maybe you can work around with it.

/jw/sample.asp, line 69
0
 
LVL 7

Expert Comment

by:ClassyLinks
ID: 6386734
oops...I didn't mean to send you those.  I was so excited to get it all working!  All you really need is the sample and to see the changes I made to your db.  Namely, I added the HO table (You'll need to add one for each office) and I changed the Item No to Item_No and For Con Use to For_Con_Use to allow for correct syntax through the ASP scripting.

Operation must use and updateable query occurs when your fpdb folder is not set for WRITE permissions for IUSR_MACHINENAME.

At that point you are writing to the db directly....you must explictly allow yoru serer to do that.

Let me know if you have any other questions.
0
 
LVL 2

Author Comment

by:newwavepro
ID: 6386755
Okay then I need to change my NUWAVE\ISUR to what in the permissions to get this to work?

To browse and author?
0
 
LVL 2

Author Comment

by:newwavepro
ID: 6386763
okay I fixed that and it worked to author and browse, no way do I want someone to have admin rights on the server egads, just a couple side notes that I can add for ease of use.  At the point where it says to override and save I would also like a part that say go back if he/she does not want to overwrite it.

Secondly at the point where it says your order has been saved, what kind of a script would jump me back to the jw/main.asp page (has not been created yet) but it will be a entry page.
0
 
LVL 7

Accepted Solution

by:
ClassyLinks earned 100 total points
ID: 6387767
No, you don't want them to have admin rights...just for the page to be able to write to the db.

The beauty of the script is....you can insert your own HTML for the redirects.

Like this:


               <input type="submit" value="Proceed with Order & Override Existing Values?" name="Proceed"></form>
<p><a href="sample.asp">Start over?</a>

AND:



     <p>Your order has been submitted!</p><br>
 <a href="main.asp">Click here to return to the entry page </a>

OR:

If you want to jump directly to main.asp after the write tothe db, without a confirmation, use this:
<%response.redirect "main.asp"%>

Any questions about that?
0
 
LVL 2

Author Comment

by:newwavepro
ID: 6389163
Those should be easy scripts to add, I am not HTML clue less i just want to make sure by adding stuff it didnt interfere with what we had already worked on.  

Thanks for your time
newwavepro
0
 
LVL 7

Expert Comment

by:ClassyLinks
ID: 6389226
You're going to be fine....and anyway, you always know where to find me ;-)

Thanks for the A.
0
 
LVL 2

Author Comment

by:newwavepro
ID: 6389855
Hi Classy well after all the hard work you did I hit a snag, I went to append query the records into a master record and instead of creating a 1 table of 183 records it created 1 table of 1098 records each office being seperate instead of combined into 1 table of 183 records.

 Nico5038 is staying in this other question I asked since this 'was' supposed to be an access question, Think you might want to look at the code and help determine if it will work.

http://otnxchange.experts-exchange.com/jsp/qManageQuestion.jsp?qid=20169009
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

In this short web based tutorial, I wanted to show users how they can still use the powers of FrontPage in conjunction with Expression Web 3.  Even though Microsoft eliminated the use of Web components, we can still use them with FrontPage and edit …
This article provides a case study on how our local youth baseball league deployed a new website, including the platform selection, implementation and benefits to the league.
The purpose of this video is to demonstrate how to automatically show related posts at the bottom of a blog post in WordPress. This will be demonstrated using a Windows 8 PC. Plugin “Yet Another Related Posts Plugin” will be used. Go to your…
The purpose of this video is to demonstrate how to reset a WordPress password if you are locked out and cannot reset the password. A typical use would be if you cannot access the email to which WordPress would send the password recovery email to…

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now