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

  • SEARCH
  • Home
  • 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 9221445
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T03:34:51+00:00 2026-06-18T03:34:51+00:00

I have an url what points a SharePoint element. I do not know the

  • 0

I have an url what points a SharePoint element. I do not know the type of the element it can be a list, a document library, an element in these or just a site url. I can only use the Web Services of SharePoint. I have to decide the type of it.

I found a solution: the GetUrlSegments WS can give this information but it can work if I call the WS at the subsite where the element is in. A know just the url I don not know what part of the url is the site url.

How can I decide of the type of the element from an url?

Or how can I decide url of the site (or subsite) from an url?

  • 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-18T03:34:52+00:00Added an answer on June 18, 2026 at 3:34 am

    I have found the answer. It is not so simple but usable.

    1. Call the sitedata.asmx.GetSiteAndWeb WS in the main site with the input url. It returns the main site url (strSite) and the subsite url (strWeb) from the given url.
    2. Call the sitedata.asmx.GetURLSegments WS in the subsite what you got at the first point with the input url.
    3. If the GetURLSegments returns nothing:
      The url points to a site.

      If the GetURLSegments returns only listId:
      The url points to a list. With the lists.asmx.GetList you can get information from the list.

      If the GetURLSegments returns with listId and itemId:
      The url points to a list item. With the lists.asmx.GetListItems you can get information from the item.

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

Sidebar

Related Questions

On my SharePoint 2010 site I have a list of items (Document Library). This
I have created a custom list in a SharePoint site and generated a Visual
I have a SharePoint page that has a hyperlink which points to a video
I have a url which points to a JSON output, however this URL requires
I have a url which normally points to a postcode lookup webservice: http://localhost/afddata.pce?Serial=xxxxxx&Password=<PASSWORD>&UserID=<UNAME>&Data=Address&Task=PropertyLookup&Fields=List&MaxQuantity=200&Lookup=BD1+3RA I
I have a Sharepoint site and today when I try to login to the
I have a long URL that points to initial page of the website and
I have a page that contains an iFrame point to a URL with parameters.
I have URL like: http://example.com#something , how do I remove #something , without causing
I have URL scheme for my blog like this: http://www.example.com/%YEAR%/%MONTH%/%CATEGORY%/%POST_TITLE%/ Now i want to

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.