Data passing betw ASP & ASPX pages

V

Vanessa

My company's internal website is written in ASP, and it has couple sections
that link to our internal software via function calls/include statements (The
website itself has a database, while our internal sofware is another
database). For example,

===============
test1.asp:
===============
<!--#include file="../mal/functionSO.asp"-->

<%
'...
'process some data
'...

var1 = request.form("var1")
var2 = request.form("var2")
var3 = request.form("var3")

TestResult = createSO (var1, var2, var3)

'...
'process more data based on the value at TestResult
'...
%>

===============
functionSO.asp:
===============
<%
function createSO (var1, var2, var3)

'it will first validate the parameters, and then insert a record, e.x. Sales
Order, into
our internal accounting software via SQL statement.

end function
%>

Recently we are changing our internal software to Navision, so all the
integration with the current software needed to be re-done on the website
(!!). However, I can't simply do a sql statement anymore. The new
integration will be using ASP.NET in C#. Here is the new flow per our new
software:

- Pass the parameters to the ASP.NET pages, the code behind it will be
written in C#.
- It will pass the data thru the Web Services, and then to the message queue.
- From there Navision Application Server will pick up the data from message
queue and their programmers will write up the codeunit at Navision for
creating the SO (for example) and return some other variables back to the
message queue.
- And the same asp.net page will pick up the return variables and display
accordingly.

Here is my question, how do I suppose to pass the variables from ASP page to
ASP.NET page and get the variables back afterwards effectively?

I don't want to change the whole ASP pages into ASP.NET pages as we have so
many customizations built into it already. I did think of a way but that
require to build down the whole flow into many different pages. And too bad
that Server.Execute can't pass the query string. That is,

===============
test1.asp:
===============
<%
'...
'process some data
'...

var1 = request.form("var1")
var2 = request.form("var2")
var3 = request.form("var3")

%>

<form post="newMethod.aspx">
<input type="hidden" name="var1" value="<%=var1%>">
<input type="hidden" name="var2" value="<%=var2%>">
<input type="hidden" name="var3" value="<%=var3%>">
</form>
<javascript>//submit the form by itself</javascript>

===============
newMethod.aspx:
===============
'it will pass data to the webservices and so on.. and get back some
variables (TestResult).

response.redirect "test1-secondpart.asp?TestResult=" &TestResult


===============
test1-secondpart.asp:
===============
<%
TestResult = request("TestResult")
'...
'process more data based on the value at TestResult
'...
%>

Besides above long way, can anyone suggest a better way? Please help!!!

Thanks!!!!
Vanessa
 
A

Anthony Jones

--
Anthony Jones - MVP ASP/ASP.NET
Vanessa said:
My company's internal website is written in ASP, and it has couple sections
that link to our internal software via function calls/include statements (The
website itself has a database, while our internal sofware is another
database). For example,

===============
test1.asp:
===============
<!--#include file="../mal/functionSO.asp"-->

<%
'...
'process some data
'...

var1 = request.form("var1")
var2 = request.form("var2")
var3 = request.form("var3")

TestResult = createSO (var1, var2, var3)

'...
'process more data based on the value at TestResult
'...
%>

===============
functionSO.asp:
===============
<%
function createSO (var1, var2, var3)

'it will first validate the parameters, and then insert a record, e.x. Sales
Order, into
our internal accounting software via SQL statement.

end function
%>

Recently we are changing our internal software to Navision, so all the
integration with the current software needed to be re-done on the website
(!!). However, I can't simply do a sql statement anymore. The new
integration will be using ASP.NET in C#. Here is the new flow per our new
software:

- Pass the parameters to the ASP.NET pages, the code behind it will be
written in C#.
- It will pass the data thru the Web Services, and then to the message queue.
- From there Navision Application Server will pick up the data from message
queue and their programmers will write up the codeunit at Navision for
creating the SO (for example) and return some other variables back to the
message queue.
- And the same asp.net page will pick up the return variables and display
accordingly.

Here is my question, how do I suppose to pass the variables from ASP page to
ASP.NET page and get the variables back afterwards effectively?

I don't want to change the whole ASP pages into ASP.NET pages as we have so
many customizations built into it already. I did think of a way but that
require to build down the whole flow into many different pages. And too bad
that Server.Execute can't pass the query string. That is,

===============
test1.asp:
===============
<%
'...
'process some data
'...

var1 = request.form("var1")
var2 = request.form("var2")
var3 = request.form("var3")

%>

<form post="newMethod.aspx">
<input type="hidden" name="var1" value="<%=var1%>">
<input type="hidden" name="var2" value="<%=var2%>">
<input type="hidden" name="var3" value="<%=var3%>">
</form>
<javascript>//submit the form by itself</javascript>

===============
newMethod.aspx:
===============
'it will pass data to the webservices and so on.. and get back some
variables (TestResult).

response.redirect "test1-secondpart.asp?TestResult=" &TestResult


===============
test1-secondpart.asp:
===============
<%
TestResult = request("TestResult")
'...
'process more data based on the value at TestResult
'...
%>

Besides above long way, can anyone suggest a better way? Please help!!!

Thanks!!!!
Vanessa


I don't what Navsion is and I don't how the 'message queue' fits in to all
this etc. so your post is a little difficult to digest.

The is phrase that I'm curious about "However, I can't simply do a sql
statement anymore. The new integration will be using ASP.NET in C#. " Why
ASP.NET?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,731
Messages
2,569,432
Members
44,835
Latest member
KetoRushACVBuy

Latest Threads

Top