Wrox Programmer Forums
|
Classic ASP Professional For advanced coder questions in ASP 3. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old January 27th, 2005, 09:05 AM
Authorized User
 
Join Date: Jan 2005
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
Default ASP -- Help Please

!) a user has to type in like
HELLO

2) the result that prints like
H
E
L
L
O

3) H-E-L-L-O

I need an example of this code that will print an input string vertically but don't forget --- a user has to type in HELLO... not first print like for i = 1 to letters(strvar)
response.write(strvar, i, 1)

but a user has to type in HELLO... pleaes give me an example of this code that will print an input string vertically and horizonally with dash... any help would be appreciated... thanks a lot.

 
Old January 27th, 2005, 12:24 PM
Authorized User
 
Join Date: Jan 2005
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
Default

<%@ Language=VBScript %>

<HTML>
<BODY>
<FORM METHOD=POST ACTION="bingo1.asp" id=form1 name=form1>
<INPUT TYPE=text NAME=item><BR>
<INPUT TYPE=SUBMIT VALUE="Click Me" id=SUBMIT1 name=SUBMIT1>
</BODY>
</HTML>


<%@ Language=VBScript %>
<% Option Explicit %>
<%
Dim fso, file, folder
Set fso = CreateObject("Scripting.FileSystemObject")

set folder = fso.CreateFolder("w:\BoSeo")
Set file = fso.CreateTextFile("w:\BoSeo\bingo.txt")
%>

<HTML>
<BODY>
<%
Dim strVar1, strVar2, i
strVar = Request.Form("item")

For i = 1 to len(strVar1)
     Response.write mid(strVar,i,1) & "<BR>"
Next
  For i = 1 to len(strVar2)
     Response.write ucase(mid(strVar, i, 1)) & "-" "<BR>"
Next
%>

%>
</BODY>
</HTML>

1. Using he file system object, i want to write the name of this file to the screen the contents of this file look like
H
E
L
L
O

2. Using the contents of the file, i want to create a second file named bingo.txt. and write out the contents of this file so it looks like this
H-E-L-L-O


any help would be appreciated. thanks lots







Similar Threads
Thread Thread Starter Forum Replies Last Post
send parameters from asp page to an asp.net form hastikeyvan ASP.NET 1.0 and 1.1 Basics 2 March 29th, 2008 01:32 AM
using asp.net web user control in asp 3.0 App i_shahid Classic ASP Professional 0 January 8th, 2008 07:32 AM
Custom HTTP 404 Problem w/ASP to ASP.NET kwilliams ASP.NET 2.0 Professional 7 November 26th, 2007 04:17 PM
Upgrading ASP w/ SQLserver 2000 to ASP.NET w/2005 cJeffreywang ASP.NET 2.0 Basics 1 April 5th, 2007 11:30 PM
Porting a sa,ple ASP CR viewer app to ASP.NET jhansen42 Crystal Reports 0 August 29th, 2003 10:26 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.