Community
All Communities
Products
All Products Communities
Industries
All Industries Communities
Developers
All Developers Communities
Worldwide
All Worldwide Communities
All Communities
Developers
User Groups
Industries
Services
Community Resources
Worldwide
Events
Learning
ArcGIS Topics
Networks
GIS Life
View All Communities
ArcGIS Ideas
GIS Life
Community Resources
Community Help Documents
Community Blog
Community Feedback
Member Introductions
Community Ideas
All Community Resources
Sign In
cancel
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
Showing results for
Show
only
|
Search instead for
Did you mean:
Cancel
Home
:
All Communities
:
Developers
:
JavaScript Maps SDK
:
JavaScript Maps SDK Questions
:
Service status
Options
Subscribe to RSS Feed
Mark Topic as New
Mark Topic as Read
Float this Topic for Current User
Bookmark
Subscribe
Mute
Printer Friendly Page
Service status
Subscribe
467
0
11-16-2012 11:52 PM
by
Udaya_BhaskerCh
eerala
New Contributor
11-16-2012
11:52 PM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
Report Inappropriate Content
Hi All,
I need to get Map Service status weather it is started or stopped, so I can show some alert to user if service is stopped.
with the below code Iam able to get weather service exists or not, but I need to get the status of it.
dojo.require("esri.utils");
var input, err;
dojo.addOnLoad(function () {
getStatus('
http://myserver/WSIPL/rest/services/Newservice/MapServer');
});
function getStatus(url) {
esri.request({
url: url,
content: { f: "json" },
callbackParamName: "callback",
load: loadCallback,
error: errorCallback,
timeout: 1000
});
}
function loadCallback(response, io) {
alert('Sucess.');
}
function errorCallback(response, io) {
if (response.message) {
alert('GIS is not available.');
}
else if (response.error) {
alert('GIS is not available.');
}
}
Thanks,
Uday
Tags
(2)
Tags:
javascript
web_developers
Reply
0
Kudos
All Posts
Previous Topic
Next Topic
0 Replies
Post Reply