If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Data Access, Manipulation & Batch Languages > ASP > Flash to ASP got it working

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 08-30-08, 21:15
myle myle is offline
(Making Your Life Easy)
 
Join Date: Feb 2004
Location: New Zealand
Posts: 1,143
Flash to ASP got it working

I have been ask to help write a site that is flash and ASP
i'm doing the ASP part but one of the problem I had was is
the ASP getting the right info

in flash you can

do something like

login_lv.username = login_txt.text;
login_lv.password = password_txt.text;
login_lv.SendAndLoad("Checklogin.asp",login_lv,"Po st");

flash will wait until it get something back you don't see the asp working

so what i did was ....

Code:
'********************************************************************
Sub WriteFormData()
Filename = Server.MapPath("Form.txt")
Line = ">>> Form Start <<<" & vbnewline
For Each x In Request.Form 
	Line  = Line & x & "="  & Request.Form(x) & vbnewline
Next
Line  = Line & ">>> Form End <<<" & vbnewline
WriteToFile Filename,line,True 
End Sub
function WriteToFile(FileName, Contents, Append)
on error resume next
if Append = true then
   iMode = 8
else 
   iMode = 2
end if
set oFs = server.createobject("Scripting.FileSystemObject")
set oTextFile = oFs.OpenTextFile(FileName, iMode, True)
oTextFile.Write Contents
oTextFile.Close
set oTextFile = nothing
set oFS = nothing

end function
the above code will append to a text file call form.txt
and write all the form request names and data to that files

to use

Paste the code to the bottom of the asp file.
the at the top just call the

Call WriteFormData

now each the the page is call it will append the text file.

hope this help somebody as this made my flash to ASP coding easyer
__________________
hope this help

See clear as mud


StePhan McKillen
the aim is store once, not store multiple times
Remember... Optimize 'til you die!
Progaming environment:
Access based on my own environment: DAO3.6/A97/A2000/A2003
VB based on my own environment: vb6 sp5
ASP based on my own environment: 5.6
VB-NET based on my own environment started 2007
SQL-2005 based on my own environment started 2008
MYLE
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On