Solved

Hiding hyerlinks in infopath

Posted on 2014-03-18
6
179 Views
Last Modified: 2015-01-09
I have a requirement in Sharepoint 2010 Infopath to hide the hyperlinks ( these are the links to navigate user to folder in sharepoint library) based on a condition.
I have a contract list and ContractsVendor Library. When item is created in Contracts List a folder is created in ContractsVendor Library by Contract Name. User will upload files in Folder.If the folder does not have any files in it , I have to hide the hyperlinks in edit ifs form/displayifs forms.

Please find attached screenshot for your reference.

Any help in this regard will be appreciated.
HideLinks.png
0
Comment
Question by:asrithap
[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
6 Comments
 
LVL 28

Expert Comment

by:clayfox
ID: 39938186
I would think you would need to have a data connection to each library or list and query each to see if there is anything returned.  Then based on that you could have a formatting rule which hid that repeating element.

You can use the "is not present" condition to check for the absence of a returned record
0
 

Author Comment

by:asrithap
ID: 39938695
Could you please elaborate on query data source is something is returned ?
0
 
LVL 6

Expert Comment

by:livanescu
ID: 39939314
in Sharepoint for ContractsVendor: create a view for the data you want returned in the order you would like to get the data)
---
in infopath designer:

to create a data connection
Data --> From SharePoint List and be sure you understand every detail as it goes along.
make sure to define when the data gets queried (on an event vs when the form gets opened)
You should find it in Data Connections

to expose the data,
create a section for each link you want to hide/show
use rules (Control Tools --> Manage Rules) and
hide the section (Formatting rules) based on your desired criteria
now this gets a bit more complicated on getting it right...
ex:
you get to define the condition
unfortunately you have to understand how it works and I'll give you a hint
on the left member, select anything that is unrestricted (strings, groups but avoid integers, booleans)
on the right member choose "Use a formula"
"Insert Function", select "All" on the left and select count on the right side
select "double click to insert field" on the first dropdown under Fields, select your newly created data connection and select the repeating group under dataFields; hit ok
note the Filter Data... option - we'll discuss it a bit later
so now your formula should say count(myVendorList)
click on Edit XPath and copy the formula and hit cancel
on the left member, select "The expression" and paste the copied formula from previous step
after this pasted formula, please  add = 0 to make up the second half of the expression
this means that count(myVendorList) = 0 is the condition; you would select Hide this control to finalize the rule.

if it depends on a field select (i.e vendor name) you can include that in filtering the data (remember Filter data... button?)

After a bit of exercise you will get fluent ;-) try small steps to understand the functionality
0
Office 365 Training for IT Pros

Learn how to provision tenants, synchronize on-premise Active Directory, implement Single Sign-On, customize Office deployment, and protect your organization with eDiscovery and DLP policies.  Only from Platform Scholar.

 

Author Comment

by:asrithap
ID: 39939491
Thank for the reply.Its little confusing as I am new to Sharepoint. Is it possible for you to put screenshots of this functionality that you have explained. Sorry to bother you , I have hope that you will guide me in solving this issue.Its bit kind of urgent.
0
 
LVL 6

Accepted Solution

by:
livanescu earned 500 total points
ID: 39940660
I will, but give me a few days to get my old sharepoint online to create something
Liviu
0
 

Author Comment

by:asrithap
ID: 39940672
Sure will wait for your implemenation using screenshots. Appreciate your help in this regard.
0

Featured Post

Office 365 Training for Admins - 7 Day Trial

Learn how to provision tenants, synchronize on-premise Active Directory, implement Single Sign-On, customize Office deployment, and protect your organization with eDiscovery and DLP policies.  Only from Platform Scholar.

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…
Microsoft SharePoint Foundation 2010 and Microsoft SharePoint Server 2010 do not offer the option to configure the location of the SharePoint diagnostic trace log files during installation.  This can, however, be configured through Central Administr…
In this video, viewers will be given step by step instructions on adjusting mouse, pointer and cursor visibility in Microsoft Windows 10. The video seeks to educate those who are struggling with the new Windows 10 Graphical User Interface. Change Cu…
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…

696 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