Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6886059
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T05:42:44+00:00 2026-05-27T05:42:44+00:00

I want to insert nodes which are fetched from other part of the program

  • 0

I want to insert nodes which are fetched from other part of the program into a NodeList.

static void NodeCheck(Node node)
{
    NodeList NodeArray = null;
    for(int i=0;NodeArray.getLength()<=i;i++)
    {
        NodeArray.item(i)=node;
    }
} 

here it goes, the NetBeans gives me the error that I need a variable here not value. what would be the solution?

EDIT: Ok let change to this

NodeList NodeArray = null;

        NodeArray.item(0)=node;

there is no iteration and still same error,,,,

EDIT NO.2:
let me make my question more clear, how can I insert nodes (single nodes) into something like an array? ant idea? the reason to do this, is to compare them with each other to see weather they are same or different.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T05:42:44+00:00Added an answer on May 27, 2026 at 5:42 am

    This line will set the NodeArray to null.

      NodeList `NodeArray` = null;
    

    In the next line you’re trying to call a method on this NodeArray which is null, this can’t work.

      NodeArray.getLength()
    

    You have to initialize the NodeArray properly to a non null value.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In Drupal, if you want to insert something into the node table, 'nid' can
I want to insert a row into the Database using SqlDataAdapter. I've 2 tables
I want to insert a vector into a set like this: set<vector<prmEdge> > cammini;
I want to insert data into a table where I don't know the next
I have an XML document and want to insert a new node at a
I have a need to insert special iconfont children nodes into a base document.
In my C++ program I want to parse a small piece of XML, insert
i want to insert the node manually to drupal database using mysql query. i
I want to write some Javascript classes which extend DOM nodes (so that I
I'm trying to do an insert into an established table which has a primary

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.