User Profile & Activity

Ahmed Dajani Member
Page
of 6
Posted: September 17, 2012 11:13 AM
Still unable to open. See attached imaged.
Posted: September 14, 2012 12:30 PM
Hans,

I was not able to unzip your sample. It seems some of the files were corrupt. Can you please resend.
Posted: September 13, 2012 6:02 PM

Hans,

I made the change as suggested but the problem still persists. The columns are misaligned. See attached image. I determined the cause of this was due to adding the first empty column. I need that column due to requirements.

I still give the user the option to hide columns. So this bug will still occur. That's a problem for us.  I tried removing the extra first column I was adding and doing some more updates on the grid. Over all it seemed to work fine, but then the misalignment came up again. See the other attached image.

I can continiously recreate this problem on my end. I don't need a work around anymore. I just need this bug fixed. Can you please inform when it is possible to receive a hotfix so I can inform my customer?

Posted: September 11, 2012 11:22 AM
Hans,

Thanks for the sample, but I could not download it. It seemed the cs file and movie were corrupt. They wouldn't unzip.

I've tried to modify one of our old samples. My findings are as follows:

- When attempting to edit a cell, WebGrid, updates the wrong column. Please see attached images. In my sample, the columns are completely misaligned which I still wasn't able to reproduce. However, in the attached sample, the wrong column is updated. Definitely an issue (Please note I use the "structure" parameter in the query string to create the column manually).

- In my project (similar setup), I noticed when the grid posts back to the server after an update that the columns are not returned in the same order when I step through with the debugger. For example:
Grid is initialized as such  col0, col1, col2, col3, col4, col5, col6  with the first two columns hidden.
After a postback, the column structure is returned as col2, col3, col4, col5, col0, col1, col6.
I don't understand why that happens, but I bet it is a reason for why my columns get misaligned.

Thank you Hans. Please keep me posted on these fixes as it is important to our project and we are past our deadline. An update date on your part would be really helpful so I may inform my client.
Posted: September 10, 2012 11:28 AM
Hans, this is fine for the initial display, but if I then make an update on the grid, it misalsigns again. Please see the attached screen shot.
Posted: September 6, 2012 9:53 AM
Hans,

Changing the DocType did not fix it. I can't get rid of the invisible columns. Unfortunately their usage is rooted in the code. It would take a massive effort to change all of that.

When can we expect an update?

Is there any kind of work around I can do when the page loads at first? A javascript call that would resize a column or something?
Posted: September 5, 2012 2:13 PM
Hans,

Upon further inspection, I found another problem. I reattached my sample.

I set the gender column to width of 25. I also set AutoWidth = false on the grid.

What I noticed was the following:

- When the grid loads and I scroll right, everything gets misaligned again.
- If I reload the grid, resize the gender column to a bigger size, then scroll right, everything looks fine.

What is the deal? This is a very frustrating error...

I don't know how to mark the above answer as not a proposed answer.
Posted: September 5, 2012 10:16 AM

WebGrid Version 7.0.7200.533 Runtime Version v2.0.50727
WebGridResources 7.0.7200.533
ISNet Version 3.0.5000.1
ISNet.WebUI.Resources 3.0.5000.400

I'm using .NET 4.0

Hans,

I just noticed something in my sample. I was adding the columns that you created, but we manually did it, I wasn't adding the col0, col1...etc (they are being added in the InitializeDataSource event). After I added them, the grid straightened out.

I looked at my original code and that's what was happening too. My datasource returned 86 columns while I was adding 87 columns. The 87th column being a custom column I needed to added due to a requirement and I didn't need to store it in the database. When I removed the 87th column, the grid rendered just fine,.

It seems the grid needs to have the exact number of columns added to as the dataasource. I think even though, the grid should render correctly. Is this a bug? I think it should be.

Thanks very much for running through this with me Hans.

Posted: September 5, 2012 1:27 AM
Hans,

Upon further testing I've closer to the reason why the error occurs. Notice in my sample the PrepareDataBinding function. Your code calls RetrieveHierarchicalStructure(), where as I am adding the columns manually. If I use your call, everything renders fine. If I add columns manually, I get the error.

Unfortunately due to a requirement, I have to add columns the way I do it in my sample. So, what is the work around?

Thanks!
Posted: September 4, 2012 2:31 AM

Thanks Hans. You did not miss anything and the sample works just fine. Still does not resolve my problem.

I was able to recreate the problem with your sample finally. I've attached a screen shot of the error.

Please let me know which feature is causing this error.


All times are GMT -5. The time now is 10:53 PM.
Previous Next