Click here to Skip to main content
15,893,487 members
Home / Discussions / C#
   

C#

 
Question[Message Deleted] Pin
JoeRip18-Aug-08 11:12
JoeRip18-Aug-08 11:12 
AnswerRe: Why doesn't Queue.Enqueue fail when Queue is locked? Pin
led mike18-Aug-08 11:22
led mike18-Aug-08 11:22 
QuestionCode To Check Email Errors Pin
Kevin Marois18-Aug-08 10:56
professionalKevin Marois18-Aug-08 10:56 
AnswerRe: Code To Check Email Errors Pin
Manas Bhardwaj18-Aug-08 12:23
professionalManas Bhardwaj18-Aug-08 12:23 
QuestionAssigning an ArrayList, i get a NullReferenceException Pin
AAKAra18-Aug-08 10:52
AAKAra18-Aug-08 10:52 
AnswerRe: Assigning an ArrayList, i get a NullReferenceException Pin
Ennis Ray Lynch, Jr.18-Aug-08 10:58
Ennis Ray Lynch, Jr.18-Aug-08 10:58 
AnswerRe: Assigning an ArrayList, i get a NullReferenceException Pin
DaveyM6918-Aug-08 12:47
professionalDaveyM6918-Aug-08 12:47 
AnswerRe: Assigning an ArrayList, i get a NullReferenceException Pin
Guffa18-Aug-08 12:59
Guffa18-Aug-08 12:59 
AnilUnni wrote:
I tried assigning using
MyPage.ApplicationList = listedApplication ;

I get a NullReferenceException, asking me to use new.


You can't possibly have gotten a NullReferenceException with that code. It's a runtime error, and you can't run the code as it doesn't even compile.

MyPage is a class, and ApplicationList is not a static member of the class, so you can't access it that way.

AnilUnni wrote:
MyPage.ApplicationList.Add(new ArrayList(listedApplication)) ;


Using "new ArrayList(listedApplication)" would only create a new ArrayList that is a copy of the first ArrayList, so that doesn't serve any purpose in your case. Adding the ArrayList to the ApplicationList property would create an ArrayList containing an ArrayList, which would work so far, but is surely not what you intended.

The problem is still that you are accessing the ApplicationList property as if it was a static member of the MyPage class.


Unless you are stuck with framework 1.x you should not use the ArrayList class at all. Use a type safe generic list instead, like List<string>.

Despite everything, the person most likely to be fooling you next is yourself.

Questionhow kill a thread that is on wait state?????? Pin
mr.mohsen18-Aug-08 9:29
mr.mohsen18-Aug-08 9:29 
AnswerRe: how kill a thread that is on wait state?????? Pin
Mark Salsbery18-Aug-08 9:45
Mark Salsbery18-Aug-08 9:45 
GeneralRe: how kill a thread that is on wait state?????? Pin
mr.mohsen18-Aug-08 10:10
mr.mohsen18-Aug-08 10:10 
GeneralRe: how kill a thread that is on wait state?????? Pin
Mark Salsbery18-Aug-08 10:26
Mark Salsbery18-Aug-08 10:26 
AnswerRe: how kill a thread that is on wait state?????? Pin
User 665818-Aug-08 9:55
User 665818-Aug-08 9:55 
AnswerRe: how kill a thread that is on wait state?????? Pin
dan!sh 18-Aug-08 10:02
professional dan!sh 18-Aug-08 10:02 
Questioncan we retrieve source code of an exe file that compiled with c#.net 2005???? Pin
mr.mohsen18-Aug-08 9:17
mr.mohsen18-Aug-08 9:17 
AnswerRe: can we retrieve source code of an exe file that compiled with c#.net 2005???? Pin
Wendelius18-Aug-08 9:22
mentorWendelius18-Aug-08 9:22 
AnswerRe: can we retrieve source code of an exe file that compiled with c#.net 2005???? Pin
JoeRip18-Aug-08 11:24
JoeRip18-Aug-08 11:24 
QuestionEvents Pin
CodingYoshi18-Aug-08 4:56
CodingYoshi18-Aug-08 4:56 
QuestionRe: Events Pin
led mike18-Aug-08 5:02
led mike18-Aug-08 5:02 
AnswerRe: Events Pin
Thomas Stockwell18-Aug-08 5:37
professionalThomas Stockwell18-Aug-08 5:37 
GeneralRe: Events Pin
CodingYoshi18-Aug-08 6:19
CodingYoshi18-Aug-08 6:19 
GeneralRe: Events Pin
DaveyM6918-Aug-08 7:59
professionalDaveyM6918-Aug-08 7:59 
GeneralRe: Events Pin
led mike18-Aug-08 8:48
led mike18-Aug-08 8:48 
GeneralRe: Events Pin
CodingYoshi18-Aug-08 9:35
CodingYoshi18-Aug-08 9:35 
GeneralRe: Events Pin
led mike18-Aug-08 11:21
led mike18-Aug-08 11:21 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.