111,094
社区成员




using System;
using System.Collections.Generic;
using System.Text;
using ASPTypeLibrary;
using Microsoft.VisualBasic;
namespace aspdll
{
public class Class2
{
public Request Myrequest;
public Response Myresponse;
public void OnStartPage(ScriptingContext sc)
{
Myrequest = sc.Request;
Myresponse = sc.Response;
Myresponse.Write(Myrequest.QueryString["test"]);//这里可以直接输出我传入的querstring的值
if (Myrequest.QueryString["zf"] == "abc")
/*但是这里,始终无法验证通过,Myrequest.QuertString是一个IRequestDictionary对象,和string无法比较,
* 但是Myrequest.QueryString["zf"].tostring()返回的值却是System_Com,我如何才能正确的进行判断?*/
{
Myresponse.Write("ok");
Myresponse.Cookies["test"] = "z";//这里也无法通过,因为Cookies只有get没有set
}
}
}
}
using System;
using System.Reflection;
using System.Runtime.InteropServices;
namespace ASPTypeLibrary
{
[Guid("D97A6DA0-A861-11CF-93AE-00A0C90C2BD8")]
[TypeLibType(4176)]
public interface IRequest
{
[DispId(1610743811)]
IRequestDictionary Body { get; }
[DispId(1610743813)]
IRequestDictionary ClientCertificate { get; }
[DispId(1610743814)]
IRequestDictionary Cookies { get; }
[DispId(1610743810)]
IRequestDictionary Form { get; }
[DispId(1610743809)]
IRequestDictionary QueryString { get; }
[DispId(1610743812)]
IRequestDictionary ServerVariables { get; }
[DispId(1610743815)]
int TotalBytes { get; }
[DispId(0)]
object this[string bstrVar] { get; }
[DispId(1610743816)]
object BinaryRead(ref object pvarCountToRead);
}
}
using System;
using System.Collections;
using System.Reflection;
using System.Runtime.InteropServices;
namespace ASPTypeLibrary
{
[Guid("D97A6DA0-A85F-11DF-83AE-00A0C90C2BD8")]
[TypeLibType(4176)]
public interface IRequestDictionary : IEnumerable
{
[DispId(1610743810)]
int Count { get; }
[DispId(0)]
object this[object Var] { get; }
[DispId(1610743811)]
object get_Key(object VarKey);
[DispId(-4)]
[TypeLibFunc(1)]
IEnumerator GetEnumerator();
}
}