Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Wokring a calculated field in SharePoint

Posted on 2011-03-23
7
Medium Priority
?
499 Views
Last Modified: 2012-05-11
I have a sharepoint list that needs to do some notifications and trying to figure out how best to do it.

The list will have a bunch of fields but lets say that field Color drives field Contact

part 1 of Question: Contact is a calculated field, how does the caluculation look for the following logic:
- if color=blue then contact=blow, joe
  if color=red then contact=red, sally
  if color=grean the contact=green, george

once if have the calculated filed right is there a way to notify that user that someone selected them?
0
Comment
Question by:Matt Pinkston
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
7 Comments
 
LVL 15

Expert Comment

by:sharepointguru14
ID: 35204023
you would need either an event receiver or workflow. You would be able to send an alert OOTB if you used a people picker but since the contact is a calculated field you will have to do a workflow that is kicked off when item added (or maybe changed) that really does the logic for you, you wouldn't even need the calculated contact column unless you are using it for something else.
0
 

Author Comment

by:Matt Pinkston
ID: 35205414
how about the first part to the question?

part 1 of Question: Contact is a calculated field, how does the caluculation look for the following logic:
  if color=blue then contact=blow, joe
  if color=red then contact=red, sally
  if color=grean the contact=green, george
0
 
LVL 15

Expert Comment

by:sharepointguru14
ID: 35207067
I'm saying you would do that through a workflow. In the workflow designer you would be able to select when this field = this....set this field to that.

I don't see the point in just doing a calculated field as that isn't going to be able to give you the alert you are looking for anyway
0
Free Backup Tool for VMware and Hyper-V

Restore full virtual machine or individual guest files from 19 common file systems directly from the backup file. Schedule VM backups with PowerShell scripts. Set desired time, lean back and let the script to notify you via email upon completion.  

 
LVL 8

Expert Comment

by:nsyyoung
ID: 35208940
Use sharepoint designer to build a simple workflow:

Step 1
--compare fields: if color field = "blue", action: set contact field = "blow, joe"
else if color = "red", action: set contact field = "red, sally"
Step 2 or maybe second wf to fire on change/new item
--comparefields: if contact = "blow, joe", action: send email "blow, joe"
else if contact = "red, sally", action: send email to "red, sally"

That's off the top of my head.  You may have more wf configuration to work out, but the wf designer in SPD should guide you through it.
0
 

Author Comment

by:Matt Pinkston
ID: 35214640
just wondering why this could not be done in just a calculated field?
0
 
LVL 8

Expert Comment

by:nsyyoung
ID: 35215446
You maybe can do the calculation, but how are you going to notify the single affected person without sending a list alert to everyone without a workflow?  
0
 
LVL 15

Accepted Solution

by:
sharepointguru14 earned 2000 total points
ID: 35215896
It can be done in a calculated field but the calculated field would result in a txt name and cannot kick off an alert. So you would then need to create the workflow to look  at that calc field, translate the name into a person and then send the alert. So it is easier and cleaner for you to just do it with a workflow and if you still want the field for display purposes that is fine the workflow can calculate and populate it for you and it can even make it a person field rather than a calculated field so that you can use other options like filtering with [ME] and stuff like that. None of that will work if you just do a calc column
0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The Scenario: Let’s say you have a quote worksheet in Excel that you use to work up sales figures and such for your clients. You utilize SharePoint to manage and keep track of these documents. You would like values from your worksheet to populate Sh…
A recent project that involved parsing Tableau Desktop and Server log files to extract reusable user queries for use in other systems. I chose to use PowerShell to gather the data, and SharePoint to present it...
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…

604 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question