Fantastic! I'm starting a Python ASP HOW-TO. I'll add this sample code if
you don't mind. Any other relevant tidbits would be helpful as well. I'd
like to walk through the entire ASP object model and show sample code on
everything (I working from the some docs at
Anybody else that's interested in contributing, shoot my anything you would
like to see in such a reference. I'm also interested in things like relative
performance numbers, productivity numbers, portability with various ASP
engines on various platforms, etc.
Send me an email directly if you'd like to help with contributions or
Thanks again, Nikolai...
From: Nikolai Kirsebom [mailto:nikolai at micon.no]
Sent: Wednesday, October 20, 1999 3:17 PM
To: python-list at python.org
Subject: Re: Convert ASP Request to sequence (PythonWin)
I don't know if I fully understand your question, but I've written a
'generic python class' which processes the Request and puts/retreives
objects in a database (all processed on ASP pages).
I use the QueryString member-method of the Request object together with
rq = string.split(Request.QueryString(), "&")
for par in rq:
token, val = string.split(par,"=")
self.__dict__[token] = val
db = win32com.client.Dispatch("ADODB.Connection")
rs = win32com.client.Dispatch("ADODB.Recordset")
s = "select * from %s where Id=%d" % (self.Table, self.Attr["Id"])
rs.Open(s, db, adOpenDynamic, adLockOptimistic, adCmdText)
for a in self.Attr.keys():
rs.Fields(a).Value = self.Attr(a)
The method 'Attr' of course just tries to fetch the value from object's
Note that you probably have to make use of the urllib module on the string.
Hope this helps.
Dirk Leas wrote in message ...
Thanks for the response..
I tried the first approach and got the following is the response: "This
object does not support enumeration". In the second approach, "r" comes back
as None. I tested both with IIS and PWS.
Where can I go to dig deeper into this?
From: Mark Hammond [mailto:mhammond at skippinet.com.au]
Sent: Tuesday, October 19, 1999 8:51 AM
To: 'LS, Python'
Subject: RE: Convert ASP Request to sequence (PythonWin)
Im not in a position to test this, but one of either:
for r in Request:
r = Request.Item(i)
From: python-list-admin at python.org
[mailto:python-list-admin at python.org]On Behalf Of Dirk Leas
Sent: Saturday, 16 October 1999 1:38
To: LS, Python
Subject: Convert ASP Request to sequence (PythonWin)
I've installed PythonWin and am trying to do some python scripting w/n
ASP. If you know the form field by name, something like "name =
str(Request("name"))" works great. How do you access Request fields if
you don't know their name -- say you wanted to write a generic dump
script that would dump all the field names and values? Seems like
there would be a way to coerce the COM Request into some type of
python sequence. Anybody know the "secret racoon handshake"?