Skip navigation
All Places > Getting Started > Blog > Authors rhia

Getting Started

7 Posts authored by: rhia Champion

Hi there, folks!

 

You may recall this blog post from a while back by Sean Fiene -- it's a great write-up on how to approach cascading look-ups in Nintex Forms using lookup columns in SharePoint. A summary is: for each set of data you want to create - you need to make a new SharePoint list. It makes sense!

 

But, I, personally, don't like having so many lists. I'd rather just have one place for myself and my clients to update. I wanted to find a new way - and, I have. I'd like to share that with you today so you can poke holes in it, or try it for yourselves. 

 

Let's look at a 1-list set-up for 4 different cascaded sets of metadata.

 

AnimalVegetable

Tier 1Unique 1Tier 2Unique 2Tier 3Unique 3Tier 4
AnimalYMammalYCatYCalico
AnimalMammalCatManx
AnimalMammalDogYPug
AnimalMammalDogBeagle
AnimalAmphibianYTree Frog
AnimalAmbhibianSalamander
VegetableYLeafyYLight GreenYIceburg
VegetableLeafyLight GreenRomaine
VegetableLeafyDark GreenYKale
VegetableLeafyDark GreenSpinach
VegetableLeafyPurpleYCabbage
VegetableRootYBrownYPotato
VegetableRootOrangeYCarrot
VegetableMarrowYOrangeYPumpkin
VegetableMarrowYellowYSpaghetti Squash
VegetableMarrowYellowButternut Squash

 

Let me explain:

 

An issue we have right now is that if we simply use a List Lookup and pull back Tier 1, we will get hella duplication of Animal and Vegetable. Perhaps some day we will have a "remove duplicates" functionality, but right now - we don't.

 

This is where views save the day.

 

  1. For each unique value in Tier 1, I put a "Y" in my Unique 1 column. For consistency, I always tag the first unique item as unique. 
  2. Then, I create a view: Tier 1 - Unique. Filter when Unique 1 = Y. 
  3. Now, when I set-up my List Lookup control in my Nintex Form, I tell it to look at the list called AnimalVegetable and return column Tier 1 using view Tier 1 - Unique. Perhaps I've named that List Lookup something crazy like "Tier 1".
  4. This is repeated for each column, as you'll see above, in terms of setting up views. So I'll end up with a Tier 2 - Unique, and Tier 3 - Unique. And, I can have as many tiers as I like. 
  5. When I want to filter my Tier 2 values based on Tier 1, I set my Lookup List to look at list AnimalVegetable, column name Tier 2, using view Tier 2 - Unique, filtered by control Tier 1. 

 

 

For me, this works really well. How about you? What are your thoughts?

 

Cheers!

 

Rhia

Seems like only yesterday it was February 2017, and I was in New Orleans at InspireX meeting everyone, and giving my very first conference presentation on governance. Now here we are, November already, and I'm eagerly starting the countdown to XChange 2018. 

 

On the fence as to whether or not you should go? Here are my top 3 reasons why it's a valuable trip:

 

3)  The Experts Lounge

 

Imagine this: a huge, ballroom-esque room, full of round tables, with 10 seats each. Each table has a card, much like at a wedding, denoting who is to sit there -- however, this is denoting the type of expertise available at each table. Document Generation. Advanced Workflows. Hawkeye. Drawloop. Every topic is covered, and there is a group of people there discussing the ins and outs of each. Ever had a question and wanted a Nintex expert to answer it to your face? This is the spot.

 

2)  Learn About All Nintex Offerings

 

Wonder if you're missing out on something Nintex has to offer because you aren't always up to date on the latest and greatest? Get a crash course in everything available to you just by walking through the corridors at Xchange! New technologies and plans are unveiled, and all products are showcased. Sessions are so varied that you can come in as an elite veteran or a Nintex newbie and find a mitful of talks to attend that are perfect for your level of learning. Last year, I went from a session explaining how to program and create my own actions, to a session about what you can find in the community & how to browse it successfully!

 

1)  A Wealth of Inspiration

 

Leaving the conference last year, I had lists and lists of things I wanted to learn more about and achieve over the course of the next year - things to improve the work I was doing, to assist my company's efficiency, and to further contribute to our corporate goals. Things I'd never even considered before, that I'd had the opportunity to see in action. Things I'd previously been scared of trying, that I now felt confident I could attack and conquer. 

 

 

These are my top three reasons for going to the conference in terms of what I can gain as a professional person at the con - but - let's be honest here; my true #1 reason to go is the fantastic friends I've made. Anywhere I go, anywhere I speak, I know there's a Nintex friend among them. This is a great bunch of folks.

 

 

CLICK HERE to register now and save!

Sometimes, you have a need to pull back a date from Active Directory to use in your workflow. Maybe you're querying for Account Expiration dates, or maybe you want to know when that employee last logged in. And maybe you need to store that in a column for some reason.

 

If that's the case, then you'll be met with a bit of grief. 

 

 

Active Directory has decided, for whatever reason, that 100-nanoseconds is the super cool way to store a date/time.  And SharePoint does not care for that. It would much prefer that you give it a format it understands, if you wish to view it as a date.

 

But, using the action Query Excel Services in our workflow, we can get a readable date. 

 

It's super simple -- the workflow, not the math -- (and I'm a workflow person not a math person) -- so let's dive right in.

 

The formula in Excel to convert the returned Active Directory time into a Date looks like this: 

(Where A1 = the cell containing your timestamp)

 

=IF(A1>0,A1/(8.64*10^11) - 109205,"")

Source: TechNet

 

 

1) Enter the formula above into cell B1 in a new Excel sheet, then, format cell B1 as a Date/Time cell. Save the Excel file into your SiteAssets library (or another library!)

 

2) Open the workflow where you wish to use the converted time, then query LDAP, and put your returned timestamp into a text variable.

 

3) Set up your Query Excel Services action like this: 

 

  • The workbook path should be the full, direct URL to the workbook
  • Ensure the "Retrieve as formatted text" is selected (or else you'll get it as Excel's timestamp)
  • Your variable can be a Single Line of Text

 

4) Use the Convert Value action to convert from text to date.

 

Bada boom, all done, and we didn't even have to TOUCH the math! Which is ideal, right!?

 

 

 

 

The Mobile forms that Nintex provides are powerful and make it so easy for users to gather data out and about.

 

But every so often, we run into a function that we're so used to using on Desktop, but isn't available in Mobile. A great example of that is the lookup() function. We have List Lookup at our fingertips, but sometimes we need to calculate a value without our users needing to select from a dropdown with only one value in it.

 

 Just because this is how I've gotten around it, doesn't mean it's the right way!

 

So let's think about what a use case scenario might be.

 

 

 

 

THE PROBLEM

 

On our Nintex Mobile form, we want our users to choose their Airplane Type from a dropdown, and then their Airplane Model - and have the form automatically select the correct Fuel Capacity and multiply that by the current fuel cost ($1.20/L).

 

However, at present, we'd need our user to select the Type from a lookup ... and then the Model from a lookup... and then the Fuel Capacity as a single item from the final lookup, in order to be able to take it out and calculate it. We don't want our users to have to select any more than the Type and Model of their plane.

 

Users can get understandably frustrated when they have to redundantly enter / select information.

 

OUR SITE & REQUIREMENTS

 

1) We have a list of airplanes, named "Airplanes" - in this list, we have the following columns:

 

  • Airplane Type
  • Airplane Model
  • Fuel Capacity

 

3) We have a mobile form where we want a user to select the Airplane Type and display a dropdown of Models along with their Fuel Capacity. 

 

4) On that mobile form, we also want to take the Fuel Capacity and multiply it by a fuel cost which will reside on the form.

 

5) We want to display the total cost to fuel the airplane to the user, live, on the iPad / Mobile form.

 

 

 

 

 

THE RESOLUTION

 

1) The very first thing we'll do is create a column in both of our lists that will combine each row of data into one, with a label in the front, automatically. We will only grab those items we require. 

 

  • Create a calculated SharePoint column - name it something like MergedAirFuel or whatever makes sense for your situation.
  • Combine each column by using a formula like:

="AIRPLANE MODEL: "&[AirplaneModel]&" FUEL CAPACITY: "&[FuelCapacity]

This produces a column that looks like:

AIRPLANE MODEL: C FUEL CAPACITY: 1600

 

2) Now that we have our merged column, we can set-up our controls on our form. Here's what we'll need:

 

  • 2 List Look-up controls

  • Calculated Value controls

3) In the first List Look-up, we just want to fetch the list of Airplane Types that we have, so we can do the following:

 

Name: AirplaneType

Source SharePoint Site: (the one your list is in)

Source List: Airplanes

List Column Name: Airplane Type

 

4) In a Calculated Value, we'll make sure the ID of the look-up doesn't show up so we can use it to filter our other look-up's control:

 

Formula: parseLookup(AirplaneType)

Name: AirplaneTypeParsed

 

5) In another List Look-up, we'll find our merged row of data dependent on the Airplane Type that was chosen earlier, like so:

 

Name: AirplaneDataRow

Source SharePoint Site: (the one your list is in)

Source List: Airplanes

List Column Name: MergedAirFuel

 

We'll also open up the "Filtering" section, and choose:

 

Filter available selections: By a control's value

Where field: AirplaneType

Filtered by control: AirplaneTypeParsed

Action when no filter applied: Show none

 

 

INTERMISSION

 

 

 

 

 

What have we achieved so far: We now have a drop down where, when the user selects their Airplane Model, they will also see the details beside it - for example:

AIRPLANE MODEL: C FUEL CAPACITY: 1600

But how do we get that Fuel Capacity out of there to work with!? 

 

RegEx, is how. Here's what we'll do:

 

I'm doing these all separately to show each step, but it could be just one field, probably.

 

6 a) In a Calculated Value field, we'll parse again to ensure we get a nice clean string to work with (without the ID) : 

 

Formula: parseLookup(AirplaneDataRow)

Name: AirplaneDataParsed

 

6 b) In a Calculated Value field, we'll use Reg Ex to strip out the Fuel Capacity first - this Reg Ex formula says "select everything up to & including "FUEL CAPACITY: " and remove it from the variable:

 

Formula: replace(AirplaneDataParsed,".+\FUEL CAPACITY: ","")

Name: FuelCapacityRegEx

6 c) In a Calculated Value field, we'll use subString to get only the first 4 digits returned, in case there is additional data after that we do not need.

 

Formula: subString(FuelCapacityRegEx,0,4)

Name: FuelCapacity

7) In our final Calculated Value, we'll determine the total cost for the selected airplane which is the Fuel Capacity times the cost.

 

Formula: FuelCapacity*1.20

Name: FullFuelCost

 

And there we have it - getting and utilizing a value from a look-up list in a Nintex Mobile form. A bit round about, and I fully expect someone to say "Rhia, you idiot, what about this way", but I welcome it -- this worked for me in a pinch. 

 

Let me know what you think. 

 

Further Recommended Reading:

 

Welcome, Workflow Chefs, to the very first Chopped! Nintex Edition.
If you’ve not seen the hit TV show on the Food Network, this is where a basket of mystery ingredients are delivered to the chef and they must concoct the most delicious dish that they are able with those items.
 

In our April Mission, it’s a tad different! You are going to be given a basket with eight (8) Nintex Workflow actions (each with their own quantities) that you will get to be quite creative with: your goal is to devise a workflow using AS MANY OF THOSE ACTIONS in ONE workflow as possible to achieve some fictional outcome (which you must also describe!) Feel free to be creative and silly… but there are still rules, naturally! (Is it an expense report workflow? Great! Is it a workflow to help Snow White organize the 7 Dwarves she lives with? Also great!)

 
The Rules:
 
  1. You can ONLY use what’s available to you in your basket (which is listed as “Action (Quantity of that Action)”, with the exception of:
    • Set a Variable
    • Action Set
    • Build a String
    • Send Notification
  2. Use everything in your basket, or just some actions – but they must compose ONE working workflow. 
  3. Post a screenshot along with a tiny write-up about the scenario that your workflow answers.

 

 

The Basket:

 

Alright, get ready to uncover your basket… your actions are:
choppedbasket
 
  • Assign Flexi-Task (2)
  • End Workflow (2)
  • Run If (3)
  • Switch (1)
  • Wait for Item Update (2)
  • Update XML (2)
  • Query List (1)
  • Calculate Date (2)

 

The Prize:

candyjar

 

If you use ALL the actions above, you'll be entered into a drawing for a big ole' jar of candy! If nobody uses all the actions, we'll take everyone who uses the highest number and put them in the drawing.  HOW SWEET IS THAT?!

 

 

 

Good luck, chefs! Don’t forget to share your recipes J

Have you ever gained sudden ownership of an abundance of Nintex workflows and forms? I have - over 350 of them - huge, undocumented monoliths, tiny stand-alone notifications - it's a bouquet of Nintex goodness and for the most part I have wrangled the workflows into a state of subservience. Generally, I only interact with these when I need to: maybe there's an error, maybe there's a change request - that's when I swoop into action.

 

But this story isn't about when things go well.

 

This is a story of how on February 21st at 3:28PM, the click of a vague button on an inconspicuous page by a well-meaning end user cost me over 5 hours of work.

 


 

 

...

 

 


 

What Havoc Did This Cause?

 

This workflow resets all of the document number references for a project. This means that all of the document numbers generated after 3:28PM were erroneous and had to be changed via individual workflows on each record, which also have their own sub-processes to run.  Oh, and, I didn't find about this until the next day.

 

 

 

How Can This Be Improved?

 

Ideas that would've made this button less tempting:

 

  • A title of the workflow that this would trigger.
  • A description of what the workflow does.

 

Some ideas that would've prevented this issue:

 

  • Audience targeting. This is in a web part, it could have been visible to only particular groups.
  • Limiting which workflows end-users can run.

 

Ideas that would have lessened the impact of this issue:

 

  • A notification at the end of the workflow to let the Nintex Admin know when this has been run, since it should be done only a few times a year. The faster we can react, the less mess there is to clear up if it's run accidentally. 
  • A requirement to gain permission at some point in the workflow from the Nintex Admin or another user to reset it, with a description of what will happen if "Yes" is chosen.
  • A workflow that undoes whatever that previous workflow did. (In my dreams.. maybe some day!)

 

Anything Redeeming About This Approach?

 

The requirement for a "Yes, I understand" to be checked to prevent accidental "Start" clicks is a great idea when you have that big tempting start button out on a page.  I also think that having a simple way to run daily workflows, like this one, is great. ... Daily workflows, mind you. Not annual ones. 

 

 

Final Thoughts: Don't Cry; Laugh!


Admittedly, when I figured out what had happened ... I laughed really hard. The fact that this button existed in the first place and that the end user not only clicked it, but also checked the "Yes, I understand" box without any idea what it was... you have to admit, that's pretty funny! 

 

 

 

I'd love to hear your thoughts! Have any of you ever run into some questionable workflow practices? 

Panels.


Panels never change.

 

But what DOES change is who can see them, and when. This is what initiated my most recent client request: "Make sure that when the Manager goes into the form, that they can only see the Manager panel, and the Software panel - and not the other two." 

 

"Simple!" I replied. Our panels are JavaScript controlled beauties; a sight to behold. Easy to hide using Nintex rules.

 

I spoke too soon.

 

"Also," they began, "Ensure that the Manager is taken directly to the Manager panel when they open their notification link."

 

My endless Googling and Nintexoogling of "target panel" was fruitless; if nothing else, I hope this blog will cement the words "target panel" forever in the search terms so that I can help future Rhias of the world come to this solution:

 

Step 1) Determine your code word. For me, it was "managers" and "software". We will focus on "managers" for this example.

 

Step 2) Ye olde JavaScript. Plop this into your Custom JavaScript settings:

 

NWF$( document ).ready(function() {
  if(location.search.indexOf("manager") > -1) {
  showPanelManager();
  }
});

 

Explanation: This JS looks at the URL, and checks to see if the word "manager" is in it. If it is, it runs the JS function "showPanelManager()" which is what controls our Manager panel.

 

Step 3) In your workflow, wherever the URL is going to be doled out to a manager, append either:

               a) If after .aspx, add a ?manager (.aspx?manager)

               b) If after other data (such as ID=360), add an &manager (ID=360&manager)

 

And, simple as that, you can now send your user directly to whichever panel is appropriate to them.

 

AND ... even if you don't need this ... think of all the cool things you could do by using a URL in this way! Append a word, and magically run ANY function! NEAT.

 

Any questions? Comments? Let me know! I'd also like to hear of the better ways to accomplish this - I am sure they exist - as well as your ideas for how else this could be used.  

Filter Blog

By date: By tag: