dc

dc

  • NA
  • 663
  • 0

C# 2010 object

Jan 21 2013 2:55 PM

In a C# 2010 desktop application I have the following line of code that gets executed continually from calling a mthod:

Attachment att = helper.createAttachmentFromInput(strExcelLocation);

This method never complains about the 'att' object already existing.  I never set the value to null.

This may not be causing an issue since when the method goes out of scope, the object is destroyed?

Can you tell me if my assumption is correct or not? Can you also explain your answer to me?


Answers (1)