CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Jun 2002
    Location
    India,bangalore
    Posts
    295

    check pointer is of which Type ?

    Hi All,

    i have a CPtrArray object m_ptrObj.
    In this i will be storing different dialogs pointer which will be dynamically created.

    Lets say i have a dialog class CTempDlg and i will store pointer of this object to m_ptrObj.

    If i have to find out if a pointer of type CTempDlg exists or not in m_ptrObj array, what should i do ?

    any suggestions?

    thanks ahead
    rajs
    Last edited by brraj; January 12th, 2006 at 02:47 AM.

  2. #2
    Join Date
    May 2005
    Posts
    4,954

    Re: pointer is of which Type ?

    if you want to determine type of pointer at runtime you can use RTTI, look at that that link:
    Run-Time Type Information

    Cheers
    If a post helped you dont forget to "Rate This Post"

    My Article: Capturing Windows Regardless of Their Z-Order

    Cheers

  3. #3
    Join Date
    Jun 2002
    Location
    India,bangalore
    Posts
    295

    Re: pointer is of which Type ?

    hi golanshahar,

    thanks for the info

    cheers
    rajs

Posting Permissions

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





Click Here to Expand Forum to Full Width

Featured