Is it possible to highlight commandlinks in primefaces? - jsf

I want to highlight commandlinks that have been clicked by setting their background to a new image.
Only the currently selected link should be highlighted and all other links should be at their default state.
Clicking on a link causes a navigation to a new webpage, but the user still sees the links and can use them for navigation.
How do I highlight the currently selected link, so it stays highlighted, until the user clicks another link?
I tried many diffrent ways, by trying to set a new styleClass when an "onclick"-Event has been fired etc.
I am out of ideas, hope you guys can help me.
Thanks very much in advance!!!

Related

Spotfire non-editable button

I am sort of new to Spotfire. There is feedback button in a dashboard I am working on, and I am trying to edit that button, but I can't find the option anywhere. The button also gets created automatically when a new page is created. Is there something I am missing? Has anyone encountered this? Any help would be
I tried to edit the HTML but there is no option for this particular button.

Enable/Disable is NOT working for Grid button

In the Invoices screen, I have a new customized field on the Header and also added a new button on the Document Details tab above the grid.
Based on the Customized field condition we need to enable and disable the button. I have added this button as a toolbar button and added enable/disable conditions in ARInvoices row selected event but it is NOT working as expected. Can you please provide your thoughts on this?
Please find the screenshot for reference.
Thanks in Advance.
Naveen, I have found a section of the Framework documentation that has some description of what you are trying to accomplish. let me know if this helps?
https://help-2020r2.acumatica.com/(W(1))/Help?ScreenId=ShowWiki&pageid=a0f8f9e9-7997-4325-bc69-b58039dd3699
So based on this it sounds link you need to "un-set" a DependsOnGrid as that is what is used to get the button to an inactive state when the grid is empty. It sounds like you are looking for the opposite.

How do I allow user to select, but not edit, text in an excel userform control whose width is smaller than the text?

Context
I want the user to review some selections they made earlier. So I display some text describing each selection on a separate control in a userform. Some of the text on the controls is long, extending beyond the width of the control. This is fine; I just want the user to be able to see all of the text without being able to edit it. To do this, I use textboxes that are "Locked" (i.e. not editable) but "Enabled" (i.e. selectable). This way, they can just click and either mouse-drag or arrow-key over to scroll through all the text.
Problem
The (small, aesthetic) problem is that when the user clicks in one of the textboxes, they get a blinking cursor, which is misleading as that is normally associated with an editable textbox.
Possible solutions
Ideally, there would be some way of removing the blinking cursor, while still allowing selection but not edition. However, I'm open to other alternatives that don't have to do with changing the width, or having a scrollbar (the textbox is too short to fit a scrollbar). The best alternative I have so far is changing the background color to a gray to make it slightly more clear that it's not editable.
P.S. I'm very familiar with VBA, so if that's part of the solution, I'm cool with that.
Thanks all!
I had a similar issue, and solved it by using these instructions to create a hidden textbox that the cursor automatically appeared in (invisible to the user).

Javascript Calendar popup from ribbon button

Does anyone have any examples of a calendar popup that can be triggered using a ribbon button on a form?
I'm looking to have a popup where the user can select a date from the calendar which will then pass the value back to the javascript that launched it. I've seen that this can be done from a html popup but my efforts to create this so far haven't really been successful, so was hoping someone could advise me on the best solution.
Thanks
I've managed to find a good calendar that I have used for this solution. It can be found at https://github.com/dbushell/Pikaday
With this I put it into a html popup that had a text box on it (which would store the selected date) and had the javascript on my ribbon button show the popup.
The download includes the js files for the calendar to function and with a little tweaking of these you can make the calendar appear immediately on opening of the popup and not hide when a date is selected. Plus the text box can have its options changed so that it isn't visible to the user.
All put together this creates a rather pleasant looking calendar popup
You can use the date parameter type from html without using javascript
<input type=date >

How to Highlight image based on selection in JSF

The images are displayed horizontally using <t:dataList>. At first no images are selected if selected it has to be highlighted. If user changes the selection the old has to go normal and new has to be highlighted. while in edit mode we need to highlight the already selected image and they may change in this mode so highlight should change. Bean is in session scope. pls provide some solution.
Take a look at Primefaces Carousel

Resources