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 8826219
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T07:05:01+00:00 2026-06-14T07:05:01+00:00

I want to parse ics files received from an Exchange using iCal4j to create

  • 0

I want to parse ics files received from an Exchange using iCal4j to create a VEvent for local processing, and modify them to create a new time proposal (COUNTER method) for sending them back to the Exchange.
The problem is that I was only able to build Calendar objects (see the code below), no VEvent.

File file = new File(PATH);
CalendarBuilder builder = new CalendarBuilder();
net.fortuna.ical4j.model.Calendar cal = null;
try {
    FileInputStream fis = new FileInputStream(file);
    cal = builder.build(fis);
} catch (Exception e) {
    e.printStackTrace();
}

Most probably, I would be able to create the replies from scratch, but if I could create them from the invite directly, I guess the result would be more likely to work. Also, I really would like to avoid parsing the files manually and hack around with string matching and things like that.

  • 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-06-14T07:05:02+00:00Added an answer on June 14, 2026 at 7:05 am

    It seems that the solution is rather simple, it is just not detailed in the examples of iCal4j, where I was looking for help. (Sorry, I am a novice programmer). But after looking into the API reference of iCal4j, I found the following:

    If you parse an ics file to a Calendar object, it will have only a few Properties, like METHOD, PRODID and VERSION in our case. But it might (and most probably will) have some Components too, like VEvent, VTodo, etc, which is the actual content of the ics file. You can get the Components’ list with

    ComponentList cl = cal.getComponents();
    

    For us, parsing, modifying and sending them will be much easier than creating them from scratch.

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

Sidebar

Related Questions

I want to parse the xml file with dynamic content using DOM parser in
I want to parse a xml file using xquery in Ruby, I found this
I want to parse data from a log file, pump it into a database,
I want to parse a dtd file and use the info I get from
I want to parse with XmlSlurper a HTML document which I read using HTTPBuilder.
I want to parse a search string similar to that provided by Gmail using
I want to parse current c++ files in a project and list out all
I want to parse the following using StringTokenizer for every string matching agent> .
I want to parse the CSS files that are loaded with an HTML page
I want to parse an XML file using SAX parser in java with this

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.