I have an Ultrawebgrid with a valuelist column (statically loaded with values at Page_Load). When the user selects a value (captured at AfterCellUpdated event), another ValueList is loaded (based on the first valuelist's selected value) and populated for the user to also select.
My problem is that when the grid is loaded, while the second column values are displayed, when clicking on the cells themselves, no valuelist dropdown is shown, because this is not created until the first column dropdownlist is updated.
What I would like to do is to have both value lists loaded and available at page_load, so as to enable editing of the second valuelist without having to change the first column's value first.
Any ideas on how this can be achieved? Which event should I hook this up to?
Hi cloucas,
Can you share your code, used to create the second drop-down? You could try to create both drop downs on page load.
Hi Nikolay
Thanks for your response;
Would you like the code in the code behind or the code in the aspx? They are quite long files, do you want the entire files or the sections relevant to the question?
Hello Nikolay
Thanks for your continuing support. I will be waiting for your update.
Chris
Hi Chris,
The only thing I can suggest is to create the ValueList completely on the client, without using page methods.
function BeforeEnterEditMode(tableName, cellName) { if (col.Key == "SubWorkTypeId") { var row = window.igtbl_getRowById(cellName); var col = row.getCell(2).Column;
if (row.getCell(1).getValue() == "1") { valueList = new Array(["Option1", "Option1"], ["Option2", "Option2"]); }
//Do this for the other options in WorkType column
col.ValueList = valueList; } }
If you have further questions, please feel free to contact me.
Hello,
I'm just checking if you managed to resolve your issue.
Thanks for your email. I have not had a chance to try your proposed solution, but I am planning on doing it this week, and I will keep you posted on the progress.
Nikolay
I have tried this solution; it seems that it is working; this however makes it necessary to update the aspx file whenever a new work category/subcategory is added to the system.
I will close this question; thank you very much for your help.
I'm following up to see if you have been able to resolve your issue.
I could not understand what is exactly the issue. Could you please clarify, and explain the steps to reproduce this behavior? Thank you.
Nikolay Hi
Thanks for your input. At this time I have no other questions on this matter; another issue I am facing is that I have a number of users complaining that whenever the grid is loaded with more and more rows, the time to refresh the totals while jumping from one cell to the other in entering data increases. They claim that after 30 or so rows, they notice a large delay (more than a few seconds). Do you know if there are any limitations?
Hello cloucas,
I'm just checking if you have any other questions.