Check the syntax of the Embed request and verify you can use a static reference to that property.
Note the difference between -
var progressBar:MyProgressBar = new MyProgressBar();
It also might be an import issue, meaning you are trying to use MyProgressBar without the line -
I don't think compilation errors are being cached and they normally have a good reason for them.
I strongly suggest to identify the root cause of the errors and fix the problematic issues.
I am able to access the file with the same path manually. The property error is vague, its just a control in the same file, also I can access it at all other places the same way and this code has been live for more than 2 years.
Its just MXML component that would have it for sure. I can see it in content assist too.
As I said, there is actually no error and this usually comes sometimes and goes away if I do a clean build. Its just this time it isn't going away..
The issue got resolved by itself. I added some dummy type casting code in one of the files where error was appearing. After a build, the error got resolved and then I reverted the code and did a build again! Voila!!
Thanks for help!!