We help IT Professionals succeed at work.

The content of element type........WSAD

Medium Priority
1,647 Views
Last Modified: 2013-11-19
Hello experts,

                 I am new to webapp development and also new to WSAD where I have encountered with the following error when I switch to tasks tab....infact I played with this tool and I do not know what exactly has happened.


The content of element type "application" is incomplete, it must match "(icon?,display-name,description?,module+,security-role*)".      application.xml      DefaultEAR/META-INF      line 5


Any help or further clarification would be glad to hear.hope this should not be tough question.

Thanks,
Harsha.
Comment
Watch Question

Commented:
Hi jdharsha,

Which version of J2EE Project did you create? It is just telling you that your application.xml
file is not valid. It is not validating. You should reorder some tags.

________
radarsh

Commented:
Post the existing XML file and the complete error here.

________
radarsh

Author

Commented:
Hello radarsh,
                    I have created in J2EE1.3 and how do I get access to the application.xml file.

Harsha.

Author

Commented:
Hello radarsh,
                    Is thi swhat u asked for.

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE application PUBLIC "-//Sun Microsystems, Inc.//DTD J2EE Application 1.3//EN" "http://java.sun.com/dtd/application_1_3.dtd">
<application id="Application_ID">
      <display-name>DefaultEAR</display-name>
</application>


and the complete error is as follows.........

The content of element type "application" is incomplete, it must match "(icon?,display-name,description?,module+,security-role*)".      application.xml      DefaultEAR/META-INF      line 5


Thanks,
Harsha.
Commented:
Hi jdharsha,

If you see the error: (icon?,display-name,description?,module+,security-role*)

module+  - means there must be one or more modules in the application tag. In you case you have none.

A correct example would be

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE application PUBLIC "-//Sun Microsystems, Inc.//DTD J2EE Application 1.3//EN" "http://java.sun.com/dtd/application_1_3.dtd">
    <application id="Application_ID">
        <display-name>DefaultEAR</display-name>
        <module id="EjbModule_1">
            <ejb>EJB.jar</ejb>
        </module>
        <module id="WebModule_1">
            <web>
                <web-uri>WebApp.war</web-uri>
                <context-root>Test</context-root>
            </web>
        </module>
    </application>

Basic you application must have  EJB module or Web Module or any other client module in J2EE.

Cheers!

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts

Author

Commented:
Hello siriki77,
                   That was very clear.Anyway I need some clarification,  can I just go with the doctype declaration i.e. without the application tag as follows?

for example if I do not have any modules for the time being....

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE application PUBLIC "-//Sun Microsystems, Inc.//DTD J2EE Application 1.3//EN" "http://java.sun.com/dtd/application_1_3.dtd">
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.