In CRM 2011, hiding picklist values to other users - dynamics-crm-2011

Values visible to Owner
Hi I know how to hide the values in textbox as shown above,But no idea how to hide values similarly in the picklist.If anyone have any idea please guide me.

There is no option to "Password hide" the text in a pick list. You do have a couple options though:
Hide the field completely using the CRM setVisible javascript method. Set the code to run on the onload of the form. A slightly more "secure" version of this is to initially mark it as invisible in the CRM Form Editor, then make it visible for the users that need it visible.
Create a new form that doesn't even contain the field for the users that don't need access. This is the most "secure" method, but it requires the security to be role based, and it looks like you need it value based.

Related

"Hidden" columns in Sharepoint 2007

I'm trying to make a custom list for inquiries, where users will fill in some information such as "Name", "Reason" etc. When they've finished filling in the information and added the item, the administrator will then go through the item, and fill in some new columns that the user hasn't been able to fill in.
I hope you understand me, otherwise you're more than welcome to ask questions!
With SharePoint designer 2007, you can use the SPSecurityTrimmedControl who enable you to show/hide form field (or site action...).
Syntax :
<SharePoint:SPSecurityTrimmedControl PermissionsString="ManageLists" runat="server">
WHAT_YOU_WANT_TO_HIDE_HERE
</SharePoint:SPSecurityTrimmedControl>
For the PermissionsString, all values HERE
You'll need to use SharePoint Designer. You will create custom new and edit forms. This way when the user fills in the new form, only certain fields will appear. Then when the administrator edits the item using the edit form, they will have access to more fields.
Please see this link for more information.
Try making a copy of the form you wish to edit by copying and pasting to the same folder. Then click on the web part for the form and the code above will highlight . Look for tags IsVisible and change it from "true" to "false". This will hide the default form. Do not delete the original form.
Click on the web part in the design view then press your right arrow. This will move the cursor to right after the web part but still within the web part zone. Go to the Insert menu, select SharePoint Controls then Custom List form. A small dialog window will appear, select the list name from the first drop down, then select the content type from the second drop down. Finally select which form you want to insert, New, Edit or Display. Click OK. The new form will be displayed under the default form, and you will then see all of the fields in order and you can add or remove as you like.
If one did not want to edit the pages, couldn't one use Jquery to hide the fields? I have done this with SPservices. to check the user credentials if you will and then if matched display the hidden fields... all this is done from a web part...just a thought...I actually learned something great today.. great replies.

Show/Hide infopath groups programmatically depending on checkbox selection

i'm new to infopath and need to ammend an existing infopath 2010 form. The users only want certain section groups to appear based on the users choice via checkboxes. Currently there are conditional rules in place for each group on the form which are working to hide/show the sections depending on whcih checkbox or checkboxes are selected.(each checkbox relates to a group). There are 19 checkboxes and related groups, the users can select 1 or more groups.
The problem is when users tick the checkbox , there is a delayed reaction seeing as there are so many condtional checks taking place on each click.The users dont like this. they would rather selct all the checkboxes they want , and then click a button to do all the work at once(instead of on each checkbox). So i've been trying to programmatically access the groups from the code behind the buttons to hide/show them depending on which checkboxes are selected. Is it even possible to set the hide/show property of a group in the code behind ?
Thanks in advance for any help
You can't show or hide sections directly with code, but you can affect data sources, which in turn can trigger rules.
See here for updating the data source programatically:
http://www.bizsupportonline.net/browserforms/programmatically-enable-disable-control-infopath-form.htm

Customize Survey fields in Sharepoint 2007

I have a Survey list which has several questions, one of those is people picker field and the another one is single line of text field.
I need to hide a perticular question ( field ) based on login user. Requirement is as below
When the user logs in as admin
a. Display ‘people picker’ and should not allow user to pick his name from people picker.
b. Hide Single line of Text field.
When the user logs in as ‘Non-Admin’
a. Display ‘Single line of Text' field and default it to have the logged in user name (without domain name).
b. Hide ‘People picker’ control.
I am thinking that we can do it by placing javascript in content editor webpart and add it in newform.apx of survey list. Can anybody give me the proper approach to get it done?
Thanks in advance
You might like to try creating a custom field control, a differnet one for each field.
Javascript is fast and involves minimal deployment, but is fiddly and can be turned off.

CRM 2011 - Custom query for subform based on value entered in field on mainform

How can I filter a subform based on a value selected in a field on the main form. The mainform is a registration for an certain education. When the user selects the education, for which he wants to make a new registration, the subform must show all the sessions planned for this education.
Thx!
I do not believe filtering is supported out of the box by microsoft. The subgrids are pretty limited.
This article might help. The author has a method to build custom views with filters, simliar to the method of filtering lookups through script. It is an unsupported hack, but may be able to be adapted to your situation.
Another option off the top of my head would be to build a silverlight list-application or custom IFrame which would filter the list based on the selected option.

How do I set a SharePoint list field in NewForm.aspx based on an input radio button?

I have modified the NewForm.aspx page for a SharePoint list, and am changing the visibility of certain div's based on the value of radio input buttons. I'd like these values to be passed to a list field as well. I have a couple of questions regarding this:
1) How can I pass the Yes/No value from the radio input to a SharePoint list field?
2) Can I drop a Yes/No field from the list on the form and use that to control the visibility of my div's?
Thanks.
Since you're already using JavaScript, on your NewForm.aspx you could probably use SPUtility.js; full disclosure, this is an open source library I maintain.
Both of the options you mention are possible. I haven't added support for Yes/No fields (as of v0.3) but you could probably do something like this.
Create a single line of text field (will hold your value in the list). Lets call it "Text Field".
Based on our radio button input, call SPUtility to set the field's value:
SPUtility.GetSPField('Text Field').SetValue('Hello world!');
You could also probably hide "Text Field" so they can't see the value change.
Or... if you wanted to go with option #2, you could help me add support for Yes/No fields. :)
Hopefully this helps.
You can use our Smart List Pro product to modify your list form. We have various capabilities, such as showing/hiding fields depending on values of other fields and user identity, tabbed interface and much much more.

Resources