cancel
Showing results for 
Search instead for 
Did you mean: 

reg onCellClick

Former Member
0 Kudos

Hi all,

I have used Oncellclick event for my columns in tableview, but this is working only for input fields and not for columns with inputhelp and dropdown.

Any pointers?

Thanks and Regards,

Sneha.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

supply the cell elements with a server event. You can do that in IF_HTMLB_TABLEVIEW_ITERATOR~RENDER_CELL_START where you instantiate the elements. E.g. for a dropdown you use the onSelect property.

Regards,

Sebastian

Former Member
0 Kudos

Hi all,

I have looked into many threads to find a solution for this, but I couldn't get any answer.

Can any of the experts suggest whether CellClick is disabled for inputhelp, and dropdown

and the reason why cellclick could not be triggered.

I have already used OnSelect but could not trigger cellclick attribute.

Thanks and Regards,

Sneha

maximilian_schaufler
Active Contributor
0 Kudos

The reason for onCellClick not working is simple:

inputhelp an dropdown are elements that require the user to click on them when making use of it. If there would be an event that caught that click on the cell, then this event would be fired, but the user would be prevented from any further use of these elements (selecting a value, ...), because the event causes reloading of the page.

You have to use some client side event that tells you when the user has finished using the element, so you can (want to) call a server event. onSelect is helpful here.

Also, read these three weblogs for detailed information on HTMLB events:

<a href="/people/brian.mckellar/blog/2004/07/18/bsp-in-depth-using-the-htmlb-event-system In-Depth: Using the HTMLB Event System</a>

<a href="/people/brian.mckellar/blog/2004/07/28/bsp-programming-handling-htmlb-events Programming: Handling HTMLB Events</a>

<a href="/people/brian.mckellar/blog/2004/08/09/bsp-programming-event-handling-in-composite-elements Programming: Event Handling in Composite Elements</a>

In addition, read this thread too maybe:

Max

Former Member
0 Kudos

Thanks Max,

Atleast I came to know why cellclick was not working, i was just thinking that any other attribute needs to be added in addition to cellclick to enable it.

Regarding Client side if i want to write the javascript i need to loop all my records in the internal table and enable submit of onclick but there r some thousands of records.

I have seen some standard PCUI applications in which the whole tableview was in display mode( none of the cells are seen as dropdowns or input helps) but once the cell is clicked the row gets selected and dropdowns and input helps appear for some of the cells.

In other words the dropdown and input helps are disabled until there is a cellclick event or row select event.

Can this be achieved using BSP?

Thanks in advance,

Regards,

Sneha.

maximilian_schaufler
Active Contributor
0 Kudos

Everything is possible

Here are two ways:

1) Server-Side

You start with a tableview in display mode, fire an onCellClick event, and on the server side you catch that event and render the tableview with the dropdown instead of a simple value.

2) Client-Side

You include the rendering of the dropdown element already in your tableview, but set it as a hidden element. You catch a client-side event when the cell is clicked, and dynamically display the dropdown and hide the value.

In any case, a tableview iterator will come in very useful, if not necessary. Client-Side method would save you a round-trip, but increases development time. Server-Side method is safer and easier to maintain.

Think about these concepts, try to make your choice after understanding them, get some helpful examples (starting with TableViewIterator.bsp in application SBSPEXT_TABLE), and you are on your way. If you have problems to overcome on the way, feel free to ask further questions.

Max

Answers (1)

Answers (1)

Former Member
0 Kudos

Thanks max for ur support.

My Problem is solved.

Best Regards,

Sneha.