Something simple: Use Server.createobject from an

Results 1 to 2 of 2

Thread: Something simple: Use Server.createobject from an

  1. #1
    Eric D. Guest

    Default Something simple: Use Server.createobject from an

    Good day everyone,<BR><BR>I have been developing with the combination ASP+VBSCRIPT+SQL2K and it works fine so far, except for the error I am getting now Object Required: Server.<BR>So the query I have is how to use the server.createobject to create an ADO connection and also a mail object from within an event handler function from something like a click on the form tick box.<BR>I can create these objects outisde the function in the page without problem, <BR>I can create inside the function the connection and recorset using createobject instead of server.createobject but not the third party mail object.<BR>I think I am not using the scope of the server object properly, here is some code from my asp page:<BR>function mytickbox()<BR>dim conn<BR>set conn=server.createobject("adodb.connection")<BR>di m Mail<BR>Set Mail = Server.CreateObject("Persits.MailSender")<BR>....m ore code....<BR>End Function<BR><BR>If anyone knows where I am wrong please feel free to reply,<BR>Thanks again, in the mean time I keep digging...,<BR>Cheers, Eric

  2. #2
    Eric D. Guest

    Default RE: Something simple: Use Server.createobject from

    Found my answer, ASP objects are available only when the script runs on the server, theregoes my event handler !

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts