Solved

How to build a dynamic matrix

Posted on 2013-11-11
5
261 Views
Last Modified: 2013-12-22
Hello experts,

I have been tasked with recreating some paper forms to make them electronic.

One form is essentially a dynamic matrix. The current form is an excel spreadsheet. Depending on the data retrieved, the number of rows and columns is dynamic.

I can retrieve the number of rows and columns by querying the db.

I have tried to recreate the form by using <asp:Table />. I can make the form look pretty good (see attached) but I run into all kinds of trouble with losing dynamic controls on postback and assigning unique ids.  I have been at this for two days but other than a pretty form... not much success.

Maybe I am tired and I am taking a completely wrong approach.  Please advise.

Vince
matrix.jpg
0
Comment
Question by:vstack
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 96

Expert Comment

by:Bob Learned
ID: 39641508
If you are creating dynamic content, you need to recreate them on post-back, at the correct place in the page life-cycle, so that view state and other such things can get processed.
0
 

Author Comment

by:vstack
ID: 39641666
Yes... the dynamic content must be recreated if I use the <asp:Table /> since I need dropdowns that the user selects from. This needs to be persisted back to the db.

This is a lot of work, recreating everything in page load or init and though I have had some success, it just doesn't feel right and it's buggy.

Perhaps, I will take a step back to allow the user, by selecting, dropdowns in another format, then persist this to the db then just create a read only form for the 'spreadsheet' look.

I was hoping to accomplish the editable 'matrix' using gridview or nested repeaters but so far it is proving to be a frustration.

Thanks

Vince
0
 
LVL 96

Expert Comment

by:Bob Learned
ID: 39642231
If you need a "spreadsheet" control, would you have the capability for a component, like Component One, Infragistics, or would you need something free?
0
 

Accepted Solution

by:
vstack earned 0 total points
ID: 39678770
I don't need a spreadsheet control. I have solved the issue by filling the matrix from other pages and presenting a 'read only' matrix.
0
 

Author Closing Comment

by:vstack
ID: 39734483
Though I appreciate the responses, none of the responses applied to my situation.
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

IntroductionWhile developing web applications, a single page might contain many regions and each region might contain many number of controls with the capability to perform  postback. Many times you might need to perform some action on an ASP.NET po…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
In this video, viewers are given an introduction to using the Windows 10 Snipping Tool, how to quickly locate it when it's needed and also how make it always available with a single click of a mouse button, by pinning it to the Desktop Task Bar. Int…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

717 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question