× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hi Peter,

You may find answers on Net.Data Forum for Developers: http://dtwdude.com/

John,

What do exactly do you mean by "Why continue to use Net.Data - IBM all but
abandoned it many years ago"?

Regards,


Rubens

-----Mensagem original-----
De: midrange-l-bounces@xxxxxxxxxxxx [mailto:midrange-l-bounces@xxxxxxxxxxxx]
Em nome de Peter_Vidal@xxxxxxxx
Enviada em: terça-feira, 7 de dezembro de 2010 19:11
Para: web400@xxxxxxxxxxxx; midrange-l@xxxxxxxxxxxx
Assunto: How to upload a .txt / .csv file to the iSeries using NET.DATA

Hi list!

I want to be able to simply upload any of the file types specified above,
from any place (obviously including the harddrive of the user) into the
iSeries. Is there anyone outthere that is doing that and that can share
your solution? I just need to know how to do it with CGI/HTML/JS/NET.DATA.

I am currently doing this:

%DEFINE {
DATABASE = "*LOCAL"
DTW_REMOVE_WS = "YES"
SHOWSQL = "NO"
library = "WHDTA"
amflib = "AMFLIB1"
PCFILE = ""
WAREHOUSE = "CVA"
%}

%FUNCTION(DTW_DIRECTCALL) SndPCFile(DTW_PAD_PGM_PARMS, IN CHAR(3) WAREHOUSE,
OUT CHAR(500) PCFILE) {
%EXEC {
/qsys.lib/whpgm.lib/D006C.pgm
%}
%}

%HTML(Report) {
<HTML>
<HEAD>

<TITLE>Indented Product Structure Listing (Multiple BOMs)
(IndPrdStrLst)</TITLE>

<STYLE>
<!--
BODY {font-family: verdana, helvetica, arial, sans-serif; font-size:x-small}
TABLE {font-family: verdana, helvetica, arial, sans-serif;
font-size:x-small}
-->
</STYLE>

<script>
<!-- Begin
extArray = new Array(".txt", ".csv");
function LimitAttach(form, file) {
allowSubmit = false;
if (!file) return;
while (file.indexOf("\\") != -1)
file = file.slice(file.indexOf("\\") + 1); ext =
file.slice(file.indexOf(".")).toLowerCase();
for (var i = 0; i < extArray.length; i++) { if (extArray[i] == ext) {
allowSubmit = true; break; } } if (allowSubmit) form.submit(); else
alert("Please only upload files that end in types: "
+ (extArray.join(" ")) + "\nPlease select a new "
+ "file to upload and submit again.");
}
// End -->
</script>

<center>

<img align=center border=0 src="/Images/PALLHeader.jpg"><br> <H3><font
color="red">Indented Product Structure Generation (Multiple
BOMs)</font></H3>

<table width=50%>
<tr>
<td>Steps to follow if you want to generate indented product structures from
a list of items that you can provide out to a Microsoft Excel ®
spreadsheet:<br> <hr> <br>

<li> Prepare a list of the items that you want to have the product structure
in an indented bill format. Make a set of UNIQUE ITEM NUMBERS to list: no
additional information is required.<br><br>

<li> Put the file anywhere in your local hard drive.<br><br>

<li> Using the BROWSE button, select the file that contains the list of
items that you prepared previously.<br><br>

<li> Once you have the right file, click on the SUBMIT button to start the
process.<br><br>

<b>NOTE: Specify a file that will only have the following file extensions:
<script>
document.write(extArray.join(" "));
</script>
<p>
</b>


<form method=post name=upform action="/cgi-bin/some-script.cgi"
enctype="multipart/form-data">
<input type=file name=uploadfile>
<p>
<input type=button name="Submit" value="Submit">

</form>

@SndPCFile("YES", WAREHOUSE, PCFILE)

</center>

</BODY>
</HTML>
%}

I am clicking on SUBMIT and what I am trying to do is being able to send
that value out to the CLP D006C. However, I also want to figure out if this
is the way to go. What I am trying to do is to upload the file with some
item numbers (maybe 10-50 per instance) and once that data is up on the
iSeries, I will run an RPG program that will read each item, blow the
product structure of the item (bill of materials) and create the results of
that explosion out to a file. The the user will be able to pull down these
results into Excel.

The process I want to create must be all in a row, step by step, one after
the other, immediately after the user hits the SUBMIT button:

(1) Send the file to the iSeries
(2) Call the RPG program to create the output data
(3) Create the data out to a file

Any advise is greatly appreciated.


PETER VIDAL
PALL CORPORATION
SR System Analyst | WH Application Development 10540 Ridge Rd., Suite 203,
New Port Richey, FL 34654-5111
727-844-2414 | Fax: 727-815-3120 | www.pall.com

"Imagination is more important than knowledge"
Albert Einstein (1879 - 1955)
--
----------------------------------------------------------------------------
----

Attention:

This communication may contain information that is confidential, privileged
and/or exempt from disclosure under applicable law.
If you are not the intended recipient, please notify the sender immediately
and delete the original, all attachments, and all copies of this
communication.


----------------------------------------------------------------------------
----


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.