Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asptoday_discuss thread: Download Method On Chilisoft


Message #1 by "Patrick Sullivan" <pat@s...> on Fri, 22 Mar 2002 03:03:41
THIS WAS ALSO POSTED IN THE asp_webserver board...

Hello, I am trying to use the download method, I have it running fine on a 
local win2k pro server but i just found out that the server my client is 
using is using the chili soft asp parser. The method I am referring to can 
be read about at 
http://msdn.microsoft.com/library/default.asp?
url=/workshop/author/behaviors/reference/methods/startdownload.asp

Here's a summary of the page, I have a select box populated with 
information, and there are subsequent select boxes that are dependent upon 
the values in the prior. So I select something in the first box, the page 
goes and downloads from another page, a string of sepparated values, which 
get populated into the next select box. Here'e the JavaScript for the 
select box's on change event:

<script language="JavaScript">
///////////////////////////////////////////////////////////////////////////
///////////////////////////
/// getting model name information///
function getModelName(Manufacturer_ID)
{
	if (parseInt(Manufacturer_ID) > 0)
		oDownload.startDownload("getModelName.asp?
Manufacturer_ID=" + Manufacturer_ID, fillModelName);
		//window.open("getModelName.asp?Manufacturer_ID=" + 
Manufacturer_ID);
}

function fillModelName(strResults)
{
	//alert(strResults);
	var arrResults = strResults.split("|");
		//myForm.elements("Manufacturer_ID").value = arrResults[0];

	var ModelNameList = document.all("ModelName");
	ModelNameList.options.length = 1;
		
	var arrResults = strResults.split("&nbsp;");
	var goModelName;
	//alert(arrResults.length);
	for (var i=0; i < arrResults.length -1; i++)
	{
		goModelName = arrResults[i].split("|");
		var newOption = document.createElement("OPTION");
		newOption.value = goModelName[0];
		newOption.text = goModelName[1];
		ModelNameList.add(newOption);
	}
}
///////////////////////////////////////////////////////////////////////////
////////////////////
-->
</script>

As you can see the download returns a separated string that i treat as an 
array. I was wondering if there is a similar method in chilisoft, or do I 
have to redo the thing?

  Return to Index