From W/ Mulpiple Outputs

I am new to programming in ASP so please forgive me if this seems trivial. I
am editing a page someone else created. The page loads a list from a
database, based on the selections (by clicking on the an item in the list it
gets highlighted) the user has the option of pressing a button to reload the
page with just what they have chosen all same page but calls others for
queries and such. This page contains a <form> then has the button to reload
with the selected events then </form>.

I am trying to add the function to output the selected events to Excel,
which I have been able to do by changing the page. The problem is we would
like two buttons, one to output to a web page, the other to a Excel. Is
possible to have two submit buttons in a form, one for web output and the
other for Excel?

View Replies


ADVERTISEMENT

1 Form, 3 Outputs

I've created a mail database for a friend, but she also wanted it to create .docs for printing for those without e-mail.

Her database looks something like this......

name|address|email|mail_type

mail_type being "email" or "post"

Sending emails to all with mail_type="email" is simple enough, and creating the doc output for the letters/envelopes is easy as well.

What I'd like is suggestions on actually outputting the docs. I need it to display 3 outputs, the HTML of the next page after form submission, the doc output for the letters and another doc output for the envelopes. Code:

View Replies View Related

Working With Database Outputs

I am establishing a connection with a database and by using a query generating output(extracting from the database). On every line of output, there is a checkbox. I want the user to select which ever output he/she wants(via the check box) and press enter at the bottom. This is working fine.

On the next page I want the page to only show the selected output(selecxted by the checkbox on the first page).

My questions.......

1) How do I count dynamic output coming out of the database?
2) After the user selects.......how do I know which line he/she selected(in order to reproduce on the second page)?
3) How do I put those values on a session variable(the database output)?

What I am trying to do is......basically create a shopping cart, which lists the item, then calculates the price on the item........and so on and so forth. I am badly stuck on the first step.

View Replies View Related

Stored Procedure Outputs!

I have a stored procedure in SQL Server 2000 named sp_FolioM with this code:
-----------
CREATE PROCEDURE sp_FolioM (@FolioTraspaso int OUTPUT)

AS

DECLARE @Existe int

SELECT @FolioTraspaso = ValorEntero FROM Parametros
WHERE Clave = 'NUMMOV'

UPDATE Parametros SET ValorEntero = ValorEntero + 1
WHERE CLAVE = 'NUMMOV'
GO
--------

Now, when i run the Query of Select ValorEntero FROM Parametros WHERE Clave = 'NUMMOV'

it returns a column with 4 rows (values)
......

In Asp i have the following code to capture the output value and i think it only writes the last value ( row #4, last one )

Values:
108106
108106
38149
38149

ASP CODE:
--------
<%@ LANGUAGE="VBSCRIPT" %>
<!--#include virtual="/../../ADOVBS.INC"-->
<HTML>
<HEAD><TITLE>Place Document Title Here</TITLE></HEAD>
<BODY>
<%
Dim objConn, objCmd, objParam
set objConn = Server.CreateObject("ADODB.Connection")
objConn.Open "driver={SQL Server};server=APALACIOS;uid=sa;pwd=;database=PDigital"
Set objCmd = Server.CreateObject("ADODB.Command")
objCmd.CommandText = "sp_FolioM"
objCmd.CommandType = adCmdStoredProc
objcmd.ActiveConnection = objConn
Set objParam = objCmd.CreateParameter ("@FolioTraspaso",adInteger,adParamOutput,4)
objCmd.Parameters.Append objParam
ObjCmd.Execute
%>
Valor: <%=objCmd.Parameters("@FolioTraspaso")%><br>
</BODY>
</HTML>

i only see Valor: 38149

what if i want to write the first value ( row number 1 )?

View Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved