Navision: How can I hide a group? - nav

I am new with Nav and I would know how to hide field on Page with C/AL code. Finally I read that you only can do it changing it with group.
How can I hide the group. I also was searching it.

The solution is that:
http://dynamicsuser.net/nav/f/106/t/31613
I read Only Works with Groups, the global variable you need to créate must be Boolean.

Related

Power Apps :I need onstart action for datacardvalue. How to implement it differently?

I need to use the value of a datacard for checking if it matches a global variable.
The problem is that the only actions that I can use is onselect (but the item is a card only for reading and can not be selected or edited) and onchange. So I used the second option (at least that works) but not if I click for first time. I need to first open another request to read and then select again the one that I need to change the field and enable the onchange action code I have written.
Is there any way to set like a value that is not appropriate and that it will change inevitably when I open the request for reading on first attempt? Setting a default value is not possible either as it has errors.
I just added the code after ; on the "on select" field of the button that navigated me on the reading the request page. So the global variable was set before actually opening the request to read.

Hide a field on changing of Ticket Status in Vtiger

Hi I want to Hide Some Fields like Ticket solution when Ticket Status is changed to open. How to do it ?
Adding to the above comments , you can also copy Edit.js inside layouts > v7 > modules > Helpdesk > resources from some other layout. There you can write your own code inside registerEventForPicklistDependencySetup function. Dont forget to remove other unwanted functions.
I would recommend using javascript for that task. Use a jquery selector to retrieve the value of ticketstatus and hide the container of the solution field if depending on the status.
You can use jQuery to perform the task. In vTigerCRM the actual name of the ticket module is HelpDesk. So to change the detail view of ticket module you need to edit layouts/vlayout/modules/HelpDesk/DetailViewHeaderTitle.tpl
file. For your reference, I am providing you with a sample.

Sitecore Conditional Showing of Fields

So I am rather new to sitecore, and it's a topic that wasn't covered during my training. My questions is just to help point me to the correct term, or documentation on a method to do the following.
I have a definition item, with a ton of field groups, what I want to do is something like:
if Value of Field X is "yes" then collapse/hide Field X or Field Group X.
Does that make sense? Is it a validation rule? or some other kind of rules, is it a workflow I need to attach? Do you place it on just the field I want to hide, or the field that triggers the action?
I appreciate any guidance.
There is nothing out-of-the-box in Sitecore to achieve what you want but there is no reason you cannot create a composite custom field type to do this. The following articles will help you achieve this:
Creating a custom Sitecore Field
Getting to Know Sitecore: Custom Fields, Part 1
Create a new control, inheriting either from Droplist (if the comparison of the value is to be text based) or Droplink (for comparison of ID). You could add a parameter in the Source field of the control to specify what the values that trigger the hide should be.
The underlying control in the Content Editor is just a standard HTML select element. Add onchange events to the control and add your Javascript handler to hide the other controls. Since I could not find a way of adding additional custom css classes to the Sitecore controls, it would be best/easiest to hide all other controls in the same collapsible group after you control. This would mean you would need to group your controls better (or logically at least).
The Javascript will be something like this (the Content Editor uses the Prototype JS framework):
if ($(this).getValue() == 'no') {
// find the parent container of this control and then hide all the next siblings in the same group
$(this).up('.scEditorFieldMarker').nextSiblings('.scEditorFieldMarker').invoke('hide');
}
You can test this by running the above in the console, change out the keyword this with the id of your field, e.g. $('FIELD2292054').
What I am not sure about is how to trigger the hide on initial load, i.e. when someone returns to an existing item, it may be possible by adding to one of the pipelines, but would be better using a JS solution if possible. I'll have a think about this and get a proper code sample up over the next few days.
EDIT: You can add an event handler to sc:contenteditorupdated to handle the content editor being rel-oaded.
document.observe("sc:contenteditorupdated", myFunction);
I wrote up a blog post and put the code on GitHub if you are interested.
Not sure if you have come across Andy Uzick's this blog post.
He wisely talks about hiding fields in the Content Editor and has also created a Sitecore Module called Hide Field Template Extension which is hosted on the Sitecore Marketplace with the full source code to extend.
After reading through and trying the extension, I do feel that it will not completely resolve your issue (how you have described it in the question).
But it will give you:
A mid-term solution to hide a few unnecessary field that some content editors would not like to view.
Fields that are only required by administrators for admin purpose - to de-clutter these fields could be hidden.
Just one thing to bear in mind that it mentions in the requirements Sitecore 6.5 & 6.6. I have not tested it in Sitecore 7. If you are using Sitecore 7, which I think you are, one could modify the source code and make it work for Sitecore 7.
Have a look and share your findings.
Happy Sitecoring!

Multiple like buttons on blog page acting as one button despite separate anchor names

I have added facebook like buttons to each entry on my blog - although I have given each entry it's own URL by including an anchor name, clicking Like on one adds to the like count of all of them. Any advice on how to sort this?
An example of the code is:
Well my initial guess is that Facebook ignores the anchor. You could try passing a parameter, e.g.
www.example.com/myblog.html?entry=1#entry1
www.example.com/myblog.html?entry=2#entry2
Good luck

how to hide the content in sitecore

I am working with sitecore and now i needs to hide some of the content item in sitcore.what is the process to hide the content'
Why do you want to hide and what do you want to hide?
You could probably setup security to only allow people with certain roles to read, write, etc certain items (and subitems) or setup that only certain roles can see certain fields.
You can probably find most of what you need here:
http://sdn.sitecore.net/Reference/Sitecore%206/Security%20Administrator%20Cookbook.aspx
Otherwise give an example of what you want to do, it might be easier to help then.
If you want to hide from a role or a user, you can setup permissions accordingly to do so. Please specify the requirement.
Perhaps not exactly what you need, but it's not really clear. You can hide items from regular (= non-admin) users by setting the checkbox Hidden as such, which can be found in the Appearance section of your item. When hidden, your items will be displayed in grey and italic in the item tree for administrators, and totally non-visible to users. Note that if you cannot find the section, you need to enable the Standard Fields under View in the ribbon.
Of course this field is also accessible via the API by any of these two means:
item.Appearance.Hidden = true; // Or false.
item[Sitecore.FieldIDs.Hidden] = "1"; // Or string.Empty.
Hide items from non admin users by using 'Hide Item' button in configure ribbon.
Protect items from non admin users by using 'Protect Item' button in configure ribbon.