CodeVerge.Net Beta


   Explore    Item Entry    Members      Register  Login  
NEWSGROUP
.NET
Algorithms-Data Structures
Asp.Net
C Plus Plus
CSharp
Database
HTML
Javascript
Linq
Other
Regular Expressions
VB.Net
XML





Zone: > NEWSGROUP > Asp.Net Forum > migration_to_asp.net.migrating_from_asp_to_asp.net Tags:
Item Type: NewsGroup Date Entered: 12/29/2007 1:45:33 AM Date Modified: Subscribers: 0 Subscribe Alert
Rate It:
(NR, 0)
XPoints: N/A Replies: 1 Views: 18 Favorited: 0 Favorite
Can Reply:  No Members Can Edit: No Online: Yes
2 Items, 1 Pages 1 |< << Go >> >|
nbop
Asp.Net User
Object variable or With block variable not set.12/29/2007 1:45:33 AM

0/0

Hi I dont know what string to put this in but Im working on this web application a total rewrite of an classical ASP site into the world of ASP.NET 2.0 and now im going to send some information to a secure server as below: and I get the error Object variable or With block variable not set.

Dim objHTTP As Object
objHTTP = Server.CreateObject(
"Microsoft.XMLHTTP")
objHTTP.Open(
"GET", "https://securewebsite.com, False)

'Sending request

objHTTP.Send()
Dim strHTML = objHTTP.responseText
objHTTP =
Nothing

'Check for error in communication

If Err.Number = 0 Then

'If no error, then send customer to TellusPay secure server

Response.Redirect("https://securewebsite.com/WebOrder/?" & Trim(strHTML))

Else

'Else print "General Error"

Response.Write("General Error!<br>" & Err.Description)

End If

I believe its connected to the beginning of the code here with Dim objHTTP as object they say in some articles Im not supposed to do that and in some places they write that I need to set the object like this 

SET objHTTP = new Server.CreateObject("Microsoft.XMLHTTP")

But then Visual studio removes the SET statement and it states that SET is no longer supported so how should I rewrite this code to get it working in ASP.NET 2.0.

any Suggestions on how I should do this?

Thanks in advance


Magnus
jamesqua
Asp.Net User
Re: Object variable or With block variable not set.12/29/2007 2:50:29 AM

0/0

The bad news is that basically none of that code will port to asp.net.  The differences between vbscript and VB.NET are as great as the differences between javascript and C#.  The good news is that what you are trying to do is not that difficult to write from scratch in VB.NET.  Here is a tutorial http://www.4guysfromrolla.com/webtech/070601-1.shtml

 

2 Items, 1 Pages 1 |< << Go >> >|



Search This Site:


Meet Our Sponsors:



Other Resources:

ng.asp-net-forum.migrating_from_asp_to_asp-net/2 - Web Programming ... Object variable or With block variable not set. 1. 1. 12/29/2007 2:50:29 AM ... how to wrap classic ASP windows scripting component (logon object ) in ASP .Net 2.0 ...
Time out a critical section - borland.public.delphi.language.delphi ... Making OS calls that may block is not. A Windows CS is a. lightweight synchro object that can get away without a kernel call if the CS ...
BUG: "Object variable or With block variable not set" error message ... Explains that when you set a public object variable of a COM component, you may ... BUG: "Object variable or With block variable not set" error message when you ...
Object variable or With block variable not set - ASP.NET Forums Object variable or With block variable not set. Last post 08-22-2008 4:53 PM by slash75. ... am not sure why? Object variable or With block variable not set. ...
PRB: Object Variable Not Set Error If Object Not Instantiated ... in this error: "Object variable or With block variable not Set" (Err = 91) If ... error message "Object variable or With block not Set" is generated. Back ...
Object variable or With Block variable not set Object variable or With Block variable not set. From: acccessaccess2003 ... RE: Object variable or With Block variable not set. From: Joel. Date Posted: 5/16 ...
91# object variable or With block variable not set - Articulate ... Whenever I open Quizmaker, I receive the message "91# object variable or With block variable not set". I click OK, it appears again, I click
Object variable or With block variable not set - Xtreme Visual Basic Talk Object variable or With block variable not set General ... Re: Object variable or With block variable not set. I think the problem is in your: ...
OTN Discussion Forums : FDM Serious Error(Object variable or ... FDM Serious Error(Object variable or With block variable not set). Posted: May 15, 2008 1:35 AM ... Detail: Object variable or With block variable not set ...
developerWorks : Rational : Extensibility Interfaces : "Object variable ... "Object variable or With block variable not set" Posted: Jan 03, 2005 08:58:17 AM ... Object variable or With block variable not set at ...



 
All Times Are GMT