Results 1 to 2 of 2

Thread: How to prevent duplicate id

  1. #1
    Sencha User
    Join Date
    Jul 2014
    Posts
    7

    Default How to prevent duplicate id

    Hi guys,
    i'm using ext js 3.4.

    I had a problem because I had two objects with the same ID.

    Is there something that can check, when i create a new obj, if the id is already present in Ext?

    I noticed that in the 4.1 there is it in dev mode. And in 3.4?

  2. #2
    Sencha Premium User
    Join Date
    Nov 2014
    Location
    Kansas
    Posts
    781

    Default

    Best bet: don't assign static ids. Instead, use the itemId config.

    You could use Ext.getCmp() to retrieve any existing component with a provided id.

    Regards,
    Brian


Tags for this Thread

Posting Permissions

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