locked
memory not release in windows store app RRS feed

  • Question

  • I have created windows store app in c#, in which i generate an image through pdf and display it and on button click i removing that image after assigning source to null and also disposing all objects memory can not get back to original state.
    Thursday, November 28, 2013 6:00 AM

Answers

  • Hi shivani,

    I will suggest you to read this blog article: http://msdn.microsoft.com/en-us/magazine/jj721593.aspx section: <Analyzing Memory Leaks in Windows Store Apps Using C# and Visual Basic>.

    And could you provide some code for further analysis? Hardly to say how to solve the problem without code analysis. And I also want to know why you need do so.

    BTW, you can use PerfView suggested in the blog to monitor the memory status.

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Wednesday, December 25, 2013 1:10 AM
    Moderator

All replies

  • The garbage collector will release memory when needed if there is no references to the object.  You can speed up the process by calling GC.Collect()

    Thursday, November 28, 2013 2:11 PM
  • Hi, 

    thanks for your reply but i have already call garbage collector but still the memory is not released.

    Friday, November 29, 2013 4:31 AM
  • Hi shivani,

    Have you tried Marshal.FinalReleaseComObject(object); ?

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Friday, December 13, 2013 3:24 AM
    Moderator
  • Hi shivani,

    I will suggest you to read this blog article: http://msdn.microsoft.com/en-us/magazine/jj721593.aspx section: <Analyzing Memory Leaks in Windows Store Apps Using C# and Visual Basic>.

    And could you provide some code for further analysis? Hardly to say how to solve the problem without code analysis. And I also want to know why you need do so.

    BTW, you can use PerfView suggested in the blog to monitor the memory status.

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Wednesday, December 25, 2013 1:10 AM
    Moderator