473,785 Members | 2,851 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Object Reference

I am having a very strange problem with my asp.net application. I am
getting error: 'Object reference not set to an instance of an object' when I
run my app from my hosting company. I have installed my application on
three different machines (including a brand new install of winxp, vs2003) at
our offices and everything seems to work fine. What could be wrong with the
server at hosting company. When i speak to them about the problem they
point the finger at my script, which I think is not a problem because it
works fine everytime I install it. I really need help with this problem.
Thanks.

Arben
Nov 19 '05 #1
4 1318
Hello Arapi,

Though the problem you have written may have number of reasons, but i feel
like that there is something which you make a reference on your development
machine is not present on the host machine.

Check out all the references you made, there respective dll;s are present as
well as in the hosting machine.

--
Wajahat Abbas

http://www.wajahatabbas.com
http://www.dotnetpakistan.com


"Arapi" wrote:
I am having a very strange problem with my asp.net application. I am
getting error: 'Object reference not set to an instance of an object' when I
run my app from my hosting company. I have installed my application on
three different machines (including a brand new install of winxp, vs2003) at
our offices and everything seems to work fine. What could be wrong with the
server at hosting company. When i speak to them about the problem they
point the finger at my script, which I think is not a problem because it
works fine everytime I install it. I really need help with this problem.
Thanks.

Arben

Nov 19 '05 #2
Hi Wajahat,
Thank you for your response. The way I do my deployment is: copy all the
contents of the bin folder to the bin folder on the hosting machine, and
aspx files to their respective folders.
I just dont understand that if my application works in three different
machines with default installation (no customized installations whatsoever)
why I am getting this error on the host machine?

"Wajahat Abbas" <wa**********@y ahoo.com> wrote in message
news:DF******** *************** ***********@mic rosoft.com...
Hello Arapi,

Though the problem you have written may have number of reasons, but i feel
like that there is something which you make a reference on your
development
machine is not present on the host machine.

Check out all the references you made, there respective dll;s are present
as
well as in the hosting machine.

--
Wajahat Abbas

http://www.wajahatabbas.com
http://www.dotnetpakistan.com


"Arapi" wrote:
I am having a very strange problem with my asp.net application. I am
getting error: 'Object reference not set to an instance of an object'
when I
run my app from my hosting company. I have installed my application on
three different machines (including a brand new install of winxp, vs2003)
at
our offices and everything seems to work fine. What could be wrong with
the
server at hosting company. When i speak to them about the problem they
point the finger at my script, which I think is not a problem because it
works fine everytime I install it. I really need help with this problem.
Thanks.

Arben

Nov 19 '05 #3
You are counting for certain objects to be present but they are not. Whether
it because they don't exist on the host machine, like the other poster
suggested, or you might lack necessary permission for using them. The bottom
line there is something in the program that is supposed to instantiate an
object and this doesn't happen.

Eliyahu

"Arapi" <aa****@gmail.c om> wrote in message
news:%2******** ********@tk2msf tngp13.phx.gbl. ..
Hi Wajahat,
Thank you for your response. The way I do my deployment is: copy all the
contents of the bin folder to the bin folder on the hosting machine, and
aspx files to their respective folders.
I just dont understand that if my application works in three different
machines with default installation (no customized installations whatsoever) why I am getting this error on the host machine?

"Wajahat Abbas" <wa**********@y ahoo.com> wrote in message
news:DF******** *************** ***********@mic rosoft.com...
Hello Arapi,

Though the problem you have written may have number of reasons, but i feel like that there is something which you make a reference on your
development
machine is not present on the host machine.

Check out all the references you made, there respective dll;s are present as
well as in the hosting machine.

--
Wajahat Abbas

http://www.wajahatabbas.com
http://www.dotnetpakistan.com


"Arapi" wrote:
I am having a very strange problem with my asp.net application. I am
getting error: 'Object reference not set to an instance of an object'
when I
run my app from my hosting company. I have installed my application on
three different machines (including a brand new install of winxp, vs2003) at
our offices and everything seems to work fine. What could be wrong with the
server at hosting company. When i speak to them about the problem they
point the finger at my script, which I think is not a problem because it works fine everytime I install it. I really need help with this problem. Thanks.

Arben


Nov 19 '05 #4
> What could be wrong with the server at hosting company. When i speak to
them about the problem they point the finger at my script, which I think
is not a problem because it works fine everytime I install it. I really
need help with this problem.
Do you program with that logic? You don't know where it's been! ;-)

Let me explain, if I may. You say you're getting an exception: "Object
reference not set to an instance of an object." This exception means that
some code in your app is referencing an object which does not exist. For
example, you create a variable, using a method, which returns null
(Nothing), and then, without checking to see whether it is nothing, you
attempt to use it as if it were the object you expect it to be.

Now, you posted no other information about this exception, such as where in
your application it occurred, which can be obtained from the Exception
thrown, using a Stack Trace. This is the first step to diagnosing your
problem. You need to identify the page that contained the line in your code
that threw the exception, and the line of code itself. Next, you need to
identify the object references in that line of code, and work backwards from
each one, identifying what operation(s) might cause that object reference to
be null (Nothing). The easiest way to do this is to implement structured
exception handling (Try/Catch), and using whatever means you choose to pass
the exception information to you, such as logging it, writing it to a file,
or displaying it in the page (which may be the only possible method on a
hosted web site, depending on your permissions).

Knowing what operation caused the object reference to be null (Nothing) will
determine the cause of the issue, and more importantly, what you need to do
to prevent it.

Assuming with no information that the fault somehow lies with your hosting
service environment, simply because you haven't managed to reproduce it on
your local development machine is a gigantic leap of illogical assumption!

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
Neither a follower nor a lender be.

"Arapi" <aa****@gmail.c om> wrote in message
news:%2******** ********@TK2MSF TNGP14.phx.gbl. ..I am having a very strange problem with my asp.net application. I am
getting error: 'Object reference not set to an instance of an object' when
I run my app from my hosting company. I have installed my application on
three different machines (including a brand new install of winxp, vs2003)
at our offices and everything seems to work fine. What could be wrong with
the server at hosting company. When i speak to them about the problem they
point the finger at my script, which I think is not a problem because it
works fine everytime I install it. I really need help with this problem.
Thanks.

Arben

Nov 19 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
2257
by: Chris S. | last post by:
I'm trying to make a graphical editor and browser for Pickled files. One aspect I'm not sure about is how to detect multiple references to the same data. For instance, say I had the Pickled data: a= b= c= d=
28
20345
by: Daniel | last post by:
Hello =) I have an object which contains a method that should execute every x ms. I can use setInterval inside the object construct like this - self.setInterval('ObjectName.methodName()', this.pinginterval); - but is there no way to do this without using the literal ObjectName? If I write 'this.methodName()' I get "Line 1 Char 1: Object doesn't support this property or method." in IE, and nothing happens in Firebird.
11
9271
by: DrUg13 | last post by:
In java, this seems so easy. You need a new object Object test = new Object() gives me exactly what I want. could someone please help me understand the different ways to do the same thing in C++. I find my self sometimes, trying Object app = Object(); Object *app = Object(); Object app = new Object();
29
2302
by: web1110 | last post by:
If I have 2 variables, A and B, referencing the same object and then do a A.Dispose(), what happens to B?
5
2520
by: Michael Moreno | last post by:
Hello, In a class I have this code: public object Obj; If Obj is a COM object I would like to call in the Dispose() method the following code: System.Runtime.InteropServices.Marshal.ReleaseComObject(Obj);
16
2903
by: anonymous.user0 | last post by:
The way I understand it, if I have an object Listener that has registered as a listener for some event Event that's produced by an object Emitter, as long as Emitter is still allocated Listener will stay alive. Is this correct? If this is correct, I've got a problem. Let's say I've got an object Customer that has an PurchaseList (Collection) of Purchase objects. Now, these Purchase objects were pulled from a datasource Datasource. The...
7
3307
by: TS | last post by:
I was under the assumption that if you pass an object as a param to a method and inside that method this object is changed, the object will stay changed when returned from the method because the object is a reference type? my code is not proving that. I have a web project i created from a web service that is my object: public class ExcelService : SoapHttpClientProtocol {
3
2774
by: User1014 | last post by:
A global variable is really just a property of the "Global Object", so what does that make a function defined in the global context? A method of the Global Object? http://developer.mozilla.org/en/docs/Core_JavaScript_1.5_Guide:Defining_Functions doesn't actually give any insight.
2
2657
by: Ralph | last post by:
Hi I don't understand why it's not working: function schedule(imTop){ this.tdImagesTop = imTop; } schedule.prototype.selectEl = function() { alert(this.tdImagesTop);
275
12404
by: Astley Le Jasper | last post by:
Sorry for the numpty question ... How do you find the reference name of an object? So if i have this bob = modulename.objectname() how do i find that the name is 'bob'
0
9645
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10324
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10147
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10090
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8971
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7499
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6739
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5511
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2879
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.