1.21 gigawatts
1.21 gigawatts

Reputation: 17850

Error: Could not resolve to a component implementation

I have a module that seems to work fine with spark components in it but when I try to load my own it gives me this error.

Error: Could not resolve <views:DisplayList> to a component implementation.

Here is the code:

<?xml version="1.0" encoding="utf-8"?>
<s:Module xmlns:fx="http://ns.adobe.com/mxml/2009" 
          xmlns:s="library://ns.adobe.com/flex/spark" 
          xmlns:mx="library://ns.adobe.com/flex/mx" 
          xmlns:views="views.*"

          width="400" height="300" 

          >

    <views:DisplayList width="100%" height="100%"/>
</s:Module>

Upvotes: 2

Views: 4273

Answers (2)

carbon fiber
carbon fiber

Reputation: 51

I was having the same problem after opening a project that had been created using Flex SDK 4.x but had been updated to 4.6.0. I tried the above 4 steps but to no avail. I then tried changing the Flex SDK in Project->Properties->Flex Compiler from the "Use default SDK (currently "4.6.0") back to "Use a specific SDK: Flex 3.6" (which was the only other one in my SDK list). Naturally, that showed the same errors. Then I set it to "Use a specific SDK: Flex 4.6.0" and all the errors went away!

I may have been able to just set it to "4.6.0" without having to first set it to "3.6" but wanted to report exactly what I had done. Something about setting it "specifically" rather than leaving the "default" button checked allowed Flex to update its internal references to the correct SDK after my Flex update I believe. I hope this saves someone some time and trouble.

Upvotes: 5

1.21 gigawatts
1.21 gigawatts

Reputation: 17850

I did four things

  • Project > Clean
  • Closed other projects
  • Restarted Flash Builder
  • Opened a project properties of a library that had similarly named classes (different packages, same class name) and unchecked include classes.

One of those fixed it. I think Project > Clean. If it happens again I'll refine this answer.

UPDATE: Running Project > Clean > Clean all Projects worked (while selecting only Clean current project did not).

Upvotes: 1

Related Questions