How to check if a library exists in another site.

  • 22 January 2019
  • 1 reply
  • 2 views

Badge

Hello,

Im fairly new to nintex so i will try to make this as clear as possible.

I have a library that sends any file put in it to another one (destination is in a list.).

Everything is working fine. But i want to check if that destination actually exists before sending it.

How do i check if a library exists within a different site?

How do i even check if a library exists?

Any help would be appreciated

#NintexWorflow


1 reply

Badge +7

I've used this process in the past. It works for both Lists and Libraries even though it's called GetListCollection.

1. Use a Call Web Service action to call the GetListCollection web method for the site in question.

   (The results need to be stored in a multiple lines of text variable since it will be XML. Mine is called strXML.)

222547_pastedImage_1.png

2. Use the Query XML action to parse out the name of the list you're looking for. (Make sure to replace <Your List Name> with the static name or variable used to hold the name of your list or library.)

222707_pastedImage_2.png

3. Lastly, test to see if the variable has any data. It should only contain data if it found the list you're looking for. If the variable is empty, the list does not exist on that site.

222708_pastedImage_3.png

Reply