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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T11:19:53+00:00 2026-05-25T11:19:53+00:00

I am working on determining if a stream is live or not. I have

  • 0

I am working on determining if a stream is live or not. I have a preexisiting file that does that (http://www.calvaryccm.com/ServiceTimes.asmx/IsServiceTime). This is what it returns when the stream is inactive:

<boolean xmlns="http://tempuri.org/">false</boolean>

When the stream is active it returns this:

<boolean xmlns="http://tempuri.org/">true</boolean>

I need help creating a xml reader to check if the webservice returns true or false. Thank you for your help.

I recently did the same thing on iOS and this is how I checked the XML.

NSError * error = nil;
NSString * responseString = [NSString stringWithContentsOfURL:[NSURL        URLWithString:@"http://www.calvaryccm.com/ServiceTimes.asmx/IsServiceTime"] encoding:NSUTF8StringEncoding error:&error];    

NSRange range = [responseString rangeOfString : @"true"];

if (range.location != NSNotFound) {
    NSLog(@"%@", responseString); 
    /// Handle active content.
   hiddenVideo.hidden = FALSE;
    hiddenAudio.hidden = FALSE;
    noService.hidden = TRUE;
    }
    else {
        NSLog(@"%@", responseString);
        // Inform user that the content is unavailable
       hiddenVideo.hidden = TRUE;
        hiddenAudio.hidden = TRUE;
        noService.hidden = FALSE;
        // Inform user that the content is unavailable
       UIAlertView *alert = [[UIAlertView alloc]
                              initWithTitle: @"Live Service"
                             message: @"There is no service going on at this time"
                             delegate: nil
                             cancelButtonTitle:@"OK"
                             otherButtonTitles:nil];
        [alert show];
        [alert release];
        HasShownAlert = TRUE; //let the other event know that the alert has already been shown.
   } 

Is there a way to do something similar in Android?

  • 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-25T11:19:54+00:00Added an answer on May 25, 2026 at 11:19 am

    You have to parse your xml. After parsing your xml you can get Boolean value true or flase. After that you can use that value in application as per your use.

    For parse the XML in android XML PULL parser is best way. Using that you can parse your xml.

    Use below link for further information

    http://www.ibm.com/developerworks/opensource/library/x-android/

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

Sidebar

Related Questions

I am new to Android and I am working on determining if a stream
I'm working on a complex network software and I have trouble determining how to
I'm working on a site, which will have several modules that either fully available
also try this but for me it isnt working. Determining image file size +
I have a site that I've been working on the the past couple of
Working with a SqlCommand in C# I've created a query that contains a IN
Working on a project at the moment and we have to implement soft deletion
Working on a project that parses a log of events, and then updates a
I am working on a java program that is essentially a chat room. This
Working on an app where I have a large collections of managed objects against

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.