Setting Object To nothing

Results 1 to 2 of 2

Thread: Setting Object To nothing

  1. #1
    Sidhartha Sinha Guest

    Default Setting Object To nothing

    Please see the code :<BR><BR>a) <BR>set lc_ObjADM018C2= Server.CreateObject("ADM018C1.clsSchemeret")<BR>sb MsgDisplay "E", fnErrorVB,lc_st_hrefpath<BR><BR>b) <BR>set lc_ObjADM018C2= Server.CreateObject("ADM018C2.clsSchemedel")<BR>sb MsgDisplay "E", fnErrorVB,lc_st_hrefpath<BR><BR>here the function sbMsgdisplay is used for redirecting the user to another page (Error Page). The function sbMsgDisplay accepts three parameters <BR>"E" - to identify that its an error<BR>"fnerrorvb" - is a function that returns the err.description <BR>"lc_st_hrefpath" - is the url of the page that is diaplyed when a user presses the OK button the Error-page <BR><BR>In the first code snippet, i am instantianting the object from the class "ADM018C.clsSchemeret" ,in the second i am instantiating the second object from the class "ADM018C2.clsSchemedel"<BR><BR>The problem i am facing is if the first object in the code stands instantiated and the second object is not ( say there is an error) then how do i set the first object = nothing. I am redirecting the user to an error page, the error page is nothing but a page that displays a message and an ok buton that takes him to another page!<BR><BR>where and how do i set to first object instance to nothing? <BR>Please reply

  2. #2
    Trung Dang Guest

    Default RE: Setting Object To nothing

    Could you post the code snippet that shows how the two pieces are placed in your routine?<BR><BR>Trun

Posting Permissions

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