function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Eddie ValdiviaEddie Valdivia 

cvc-elt.1: Cannot find the declaration of element 'ApexClass'

Helo Everyone

I have to create a new trigger to send some data with an API in Mandrill. I started to do it over Eclipse Version: Mars.2 Release (4.5.2). Downloaded all the Force.com elements to work. As soon as I started to work, I connected to salesforce and the Force.com download all the Apex Classes, TRiggers and any one else element, with their Metadata files.

The main problem is that all the xml files has the error Cannot find the declaration of element 'ApexClass'. those errors seems to create conflict when I tried to deploy. Any one knows how to fix the problems with the xml files?
 
FearNoneFearNone
Right click on your project folder -> Hover over the "Force.com" menu -> Select Add/Remove Metadata Components -> Click on the Add/Remove button -> Select ALL -> OK
Yahor VolkauYahor Volkau
I had the same issue in VS Code and resolved it:
Go to VS Code: File => Preference => Settings => (search for) Validation ==> Click on XML (from the left Nav) and uncheck "Validation"
Pallavi Rajmohan 13Pallavi Rajmohan 13
Yahor Volkau Thanks and it worked fine in VS code
Uvarani Parameswaran 9Uvarani Parameswaran 9
@Yahor Volkau   Thank you so much, it works.

 
aliaa12 joe 4aliaa12 joe 4
Great Post! Thank you for visiting here. https://tractorsinfo.com/mysainsburys/
mr offermr offer
hi,
you can chek this:
کد تخفیف دیجی کالا (https://offerdaily.ir/brands/digikala/)
Sanjay Patil 10Sanjay Patil 10
 You can genarate Manifest file with name "package"(xml file)
and copy paste below code.

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Package xmlns="http://soap.sforce.com/2006/04/metadata">
    <types>
        <members>*</members>
        <name>ApexClass</name>
    </types>
    <types>
        <members>*</members>
        <name>ApexComponent</name>
    </types>
    <types>
        <members>*</members>
        <name>ApexPage</name>
    </types>
    <types>
        <members>*</members>
        <name>ApexTestSuite</name>
    </types>
    <types>
        <members>*</members>
        <name>ApexTrigger</name>
    </types>
    <types>
        <members>*</members>
        <name>AuraDefinitionBundle</name>
    </types>
    <types>
        <members>*</members>
        <name>LightningComponentBundle</name>
    </types>
    <types>
        <members>*</members>
        <name>StaticResource</name>
    </types>
    <version>54.0</version>
</Package>