Results 1 to 5 of 5

Thread: assiging null to qvector

  1. #1
    Join Date
    Oct 2007
    Posts
    201
    Thanks
    19
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Question assiging null to qvector

    HI all
    Im new to Oops programming. I ve a member like
    QVector<qint32*> m_iElem;

    Can any body tell me how to assign null value to this. i tried to searc on net but didnot find.

    Thank you all.
    Cheers,
    Phillip



    --- Please post the solution you got to solve your problem. It may help others.

  2. #2
    Join Date
    Oct 2007
    Posts
    2
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: assiging null to qvector

    hiiiiiiiiiii

  3. #3
    Join Date
    Oct 2007
    Posts
    201
    Thanks
    19
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Wink Re: assiging null to qvector

    Quote Originally Posted by nithinin2001 View Post
    hiiiiiiiiiii
    Hiiiiiiiiii

    can u help me?
    Cheers,
    Phillip



    --- Please post the solution you got to solve your problem. It may help others.

  4. #4
    Join Date
    Oct 2006
    Location
    New Delhi, India
    Posts
    2,467
    Thanks
    8
    Thanked 334 Times in 317 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: assiging null to qvector

    how about using
    Qt Code:
    1. QVector<T> & QVector::fill ( const T & value, int size = -1 )
    To copy to clipboard, switch view to plain text mode 
    ??

    u can use m_iElem.fill(0);

    hope it helps

  5. #5
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: assiging null to qvector

    What is wrong with m_iElem[x] = 0; ?

Similar Threads

  1. Problem at time compilation in traslation of language
    By thomasjoy in forum Qt Programming
    Replies: 3
    Last Post: 22nd May 2007, 14:18

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.