Skip to content

8.4: Error in Java Activecode #197

Open

Description

@habibasorour

Description

This Java block is giving an error, and I dont see the results on the page

Screenshot

Image

Activity

  1. pearcej commented on Aug 5, 2026

    @pearcej
    Collaborator

    @habibasorour This works fine with a different filename.

    Image

    However, I don't think changing the file name is the way to go. Since we do not know how many times the code will be run, and there is too much detail already in this short book. I would delete this listing entirely and fix the prose to make the next listing make sense.

  2. habibasorour commented on Aug 5, 2026

    @habibasorour
    ContributorAuthor

    @pearcej I will work on this

  3. habibasorour commented on Aug 5, 2026

    @habibasorour
    ContributorAuthor

    @pearcej looking at the code in this section, every <datafile> tag has the name myfile so i think this is what is causing the issue.

    This subsection is about writing a file in Java, and I think this listing is the main part of the whole section. I want to try to change it to a new name instead of just myfile and call it like myfilenew so that it is just unique for this and I think this might solve it. What do you think?

  4. pearcej commented on Aug 5, 2026

    @pearcej
    Collaborator

    This is a fine idea, but I still think we should remove the earlier code because of the possibility of running the code multiple times.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions