Infopath Form to submit data to two sharepoint lists - sharepoint

Novice in Sharepoint and looking for some advise.
we are trying to setup a infopath form with the below fields.
ReqID (Autogenerated with a workflow based on ID like Req-1 etc.),
Description,
User,
Date,
Testing,
Tester,
Date
when the user submits the form, we would like to save the information to two separate lists on sharepoint like...
List A - ReqID, Description, User, Date
List B - ReqID, Description, Testing, Tester, Date
Can someone please advise if this is doable without using any coding.
Thank you so much for all the help.

Several possible solutions:
One list:
If it is a matter of hiding clutter from selected users then: create one list for all of the fields and then create two views, one with your first set of columns and the other with the second set of columns. This has the advantage of no duplication of data, and if you need to update the Description column, it only has to be done in one place.
Two lists:
From the InfoPath form, post all of the fields to the first list and create a View that only displays what's needed for the "A" users. Create a workflow that adds a new item to list "B" with only the data needed.
Three lists:
From the InfoPath form, post all of the fields to a master list. Create a workflow that copies selected fields to List A and to List B. This has the advantage of the master list being an unchanged source of the original data for audit or tracking purposes.
Using Web Services
I believe InfoPath can call web services. This will be more like "coding", but you can write data directly to SharePoint lists using SharePoint's REST API.

Related

Auto generating unique ID in Power apps and Microsoft Forms

I am tasked in developing a form which is going to record and store data into a SharePoint list (Office 365 online SharePoint) So far I have been looking into two different methods I am not sure if they are suitable given the requirements of the work scope. The requirement is that each form has to be assigned to a unique ID/serial number and the data in the form has to be passed to a SharePoint list.
The first method that I have looked at is using Microsoft Forms to be the online form to collect the data and Power Automate to get the data and put it into a SharePoint list. The problem is I do not know if there is a way to assign a unique ID on the form itself before submitting the form. Is there a way or method where I can autogenerate a unique ID/serial number on a form before submitting it ?
I am also looking at using PowerApps to create a form which will be linked to the SharePoint list. Is there a way to autogenerate a unique ID/serial number and prepopulate it on the form?
The most flexible, customizable solution would be PowerApps
PowerApps will connect directly to Sharepoint as a data source. There is most definitely a way to autogenerate a unique ID/serial number in PowerApps. Look into the GUID() function.
Some great use cases for Microsoft Forms include:
External users (those outside your Active Directory tenant) need to fill in data
The form is dead simple (few questions, minimal logic, etc.)
Each Microsoft Form submitted also has an ID (Response ID)...
But it is not suitable as a GUID/serial number. You could add one in Power Automate, using the guid() expression before creating the record in Sharepoint:
The entire workflow ends up looking like this:

Converting SharePoint List Form to a PowerApp

I'm looking for input on the best approach to converting a SharePoint list form to a PowerApp. The list currently has the following field type:
15 text fields
5 choice fields
5 multi-select choice fields
3 multi-line text fields (not rich text)
There are 20,000+ items in the list, with 1k+ new items added every month.
When creating the PowerApp, should each choice field be converted to a new list? I'm wanting to make the fields as dynamic as possible and avoid hard coded values.
I'm not opposed to moving all of the list items to a CDS entity if it helps.
You can use PowerApps to customize the SharePoint list form. There is a command in the command bar of a modern list to do that
If you don't want to use Choice fields, you can use simple text fields and in PowerApps connect to SharePoint lists as the source of the dropdown options. Then you can let the end users maintain the values for the dropdowns easily.
With this approach, the SharePoint list maintains all other functionality, i.e. you can use list views and embed list view web parts in SharePoint pages. A customized form will not work on a mobile device, though.
You can also build a stand-alone PowerApp that stores items in the SharePoint list. This is independent of the SharePoint list form customization. Such an app could be used on a mobile device, but there are limitations around the number of list items that the app can pull from the SharePoint server at any one time. It may not be suitable for big lists.
PowerApps is easy to learn and there are lots of resources just a web search away.

Create Unique Sub List within List in Sharepoint Online

Im trying to create a Unique sub list within a list in Sharepoint Online (2013).
I realize that sub lists arent exactly possible and you can use lookup fields to attach another list. This doesn't seem like it will work for my situation.
I am trying to have a list item that allows you to upload unique files per list item. For Example:
Reports May 2015
---School.xml
---Food.xml
Reports Jun 2016
---University.xml
---Beach.xml
Each list item will have a set of unique files related to it.The user needs to be able to make the List item themselves (Reports ... in this case), this will of course have other fields and descriptions attached to it (hence the list) and then be able to upload unique documents to that list item.
Im having problems figuring out how to do this in SharePoint. If there is another way to go about this better i am up for it.
You're right - sublists aren't a thing in SharePoint. Reading your requirements, I'm not sure if you need two lists to get what your looking for. Would it be possible to have a single Document Library with a custom field for "Category" or "Report Month". This field could either be a Single line of text field or Choice field. From there you could create a custom view to group by this field and give the hierarchical view from your example.
If you need separate metadata for the grouping/top level, you may need to use Lookups. If I was putting together the solution, I would set up a List and a corresponding Library with a Lookup field to the List. Each of the documents uploaded to the Library would reference the List via that Lookup. To provide an interface for interacting with both within the same view, you'd need to frontend it with some custom code such as a SharePoint-Hosted App.

How to create a sharepoint list column that links to another list that is editable

I'm not sure if the title is a proper descriptor of what I'm trying to achieve here, hopefully it's close enough. I'm not a SharePoint expert, but I'm comfortable with creating forms and workflows as necessary to get something like this to work.
Basically, I need to have two separate SharePoint lists that are linked together, but one list needs to have row level security to hide data from other users that shouldn't see it. I need the column that is being linked to be an editable text box though, rather than a simple lookup field.
For example:
List A
Customer (text)
Description (text)
Sales People (person, multiple selections allowed)
Expenses (linked field)
List B
Customer (text)
Expenses (number)
Created by (just a reference that the sales people would actually "create" each row here)
Essentially, multiple people can be assigned to a customer in list a. The "sales people" are assigned by another user who actually creates the item for list a. I need to be able to have the people who are assigned as "sales people" to have a text box where they can enter their expenses, but on an individual basis, that would then be stored in list b with row level permissions to prevent them from seeing each others expenses totals.
List B would be able to show each sales person their full list of expenses across all the customers they are connected to, but not be able to see each others expenses. It's not a problem if the person creating the item for List A ends up with items in List B that are 0, but I need to be able to have the Expense field be an editable text box from a form that allows the sales people to enter their total expenses for that customer.
If I was building a custom application, this wouldn't be difficult to do, but I can't for the life of me figure out how to do this in SharePoint, or if it is even possible.
This is possible, but it will require custom development, using the SharePoint Object Model. Create your two lists and then you can either create a javascript/HTML based solution using libaries like jQuery and SPServices, or you can create a custom web part and use C# to update the lists. There's lot of examples out on the internet on how to do this. Write some code, and bring any problems you have with the code back to StackOverflow.

Mapping Infopath fields to Sharepoint columns

Any one has any idea how to map an infopath field to a sharepoint column of type choice? The infopath field is a repeating field, so the user can select multiple options, I want to be able to map those to the choice field in sharepoint. Any ideas?
update:
What I'm trying to do is the following. I have a choice column in sharepoint which allows user entered values. In infopath, I have a repeating field. I'm binding the field to a dropdownlist. The dropdownlist gets filled by a webservice. This dropdownlist is in a repeating section, so the user can choose to select from multiple dropdownlists. So lets say the user adds 2 dropdownlists, and selects an option from each dropdownlist. I want to be able to add those selections as choices in the sharepoint choice column.
SharePoint list is a flat structure, and because of that Infopath does not allow you map repeating sections to list columns.
You might wanna consider the following workaround:
Store Infopath form to one library
(along with non-repeating fields)
Use one of these custom activities to extract data from
repeating table and copy it to
another list
Create a custom data view or a web part to display these items (if
necessary)
This approach can be useful if you need to do some additional tasks with the repeating data.
When you are promoting fields within a repeated section into SharePoint columns, the options available are to promote the column as:
first (i.e. only the first selection is promoted)
last
count
merge (I believe this merges all the selected values together into a single entry)
screenshot http://img4.imageshack.us/img4/5539/repeatinggrouptr3.png
Is it not similar to Create a Repeating Cascading List from:
a Flat Data Source or
a Hierarchical Data Source ?
If it is, may be those two articles may give you some pointers.
Depends on the type of choice field it is.
If it is a Multiple Select (checkboxes) Choice field, you can set the field through the object model (from the sharepoint site) or through the web service, by using ";#" for each item that you want to check mark, where is the value which is listed by the checkbox. I don't remember what the option is for single choice only, but it is something of the same nature. If you are talking about lookup fields, it has to do with the index number of the field from the list you are looking it up from. Also, there is additional steps if the choice field allows users to input or specify their own options.

Resources