|
Albert83 wrote: I have datalist which is inside a rounded cornered table
I think UserControl suits your requirement.Just think about a usercontrol.
|
|
|
|
|
Thanks. But how would I embed a general datalist inside the table? and then reuse it. The datalist id and contents will be different on various pages. The table is the same.
|
|
|
|
|
Make a usercontrol and embed the datalist inside the table.Thats all.Just try.
|
|
|
|
|
Ok. I will try seems to be pretty simple. Thanks.
|
|
|
|
|
I have a grid view, I set the cells' back-color of this grid view by javascript code(on right-mouse-click). When I hit a submit button, the page refreshes and the cells' color becomes white again.
I find a way to save the color of any cell before the refresh of the page.
|
|
|
|
|
You need to use a hidden field, or similar, to pass the value in question back to the code behind, and then write code to restore that value.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
I know how to pass values to code behind. but how can I know what cell was clicked? the grid view cell has no position or index property..
|
|
|
|
|
Hi Everybody
i want to upload my website in local server then it showing error this type-
a name was started with an invalid character. error processing resource 'http localhost
how we solve this types of error plz help me.
thanks and regards
vivek
|
|
|
|
|
A better and quick way to troubleshoot such errors are by searching[^].
|
|
|
|
|
Hi,
How to display the data from database as slide show.
Eg:
There is 20 rows of data in database, i need to show the first 5 in first 10 seconds, next 5 in next 10 seconds... and go on by displaying each 5 data per 10 seconds.
Is there any .net control to show such condition?
Thankyou,
YPKI
|
|
|
|
|
You would need to use AJAX, or at least a javascript timer, to do this. I doubt there's any control for it out of the box, but you never know.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Hello,
I have an ASP.NET website with a sql backend. I am utilizing the membership provider model within visual studio. The site can only be accessed by entering the correct username and password.
I have approximately 20 pdfs on the website. I need to be keep a log of who has "read" which documents. I am creating a page that lists all documents to be read. I have a check box before each url. The user will need to check off which documents he/she has read and then submit the page. When the user clicks on the link again to see the remaining documents to be read, the page should only display those documents that the user has not yet checked off.
I can store the document list in a sql database but I am not certain how to maintain the log of documents for each user and how to only display the list of those documents that have not yet been read.
Any thoughts or assistance would be appreciated. Also if there is more efficient way to do this please let me know.
Thank you in advance for your assistance.
Allison
|
|
|
|
|
This sounds messy to me. If I check an item, it disappears from the list ? I would have thought you would allow users to request a document they have viewed before, and that you'd track what they read automatically, through what documents they requested from your system.
I would expect you're going to store in the DB which ones were marked read, then run SQL to request the unread ones to view.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Christian,
Thanks for your quick reply. You bring up a good point, I see that I probably did not clarify this as well as I should.
The list of documents that need to be read is a separate page that serves as a central location to store all those documents that still need to be confirmed as being read (by the user). This list contains the name of the document, a link to the document and checkbox that is to be checked once the document is read. The documents are located on a variety of pages throughout the site.
Hopefully that helps. Sorry for the initial confusion.
Allison
|
|
|
|
|
OK - I still think that you should be detecting when a document is requested, and marking it as read as a result, and letting the user view ALL documents in order to select which ones to mark as read ( so they can unmark some ). From there, if you have them marked as read in the DB, it's easy to write SQL that returns the list of unread documents, so you can display that.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Christian,
Thanks that makes perfect sense, however (per the requirements provided to me), I need for the user to actually check a box or something to confirm that they have read the document. I really appreciate your help.
Allison
|
|
|
|
|
Has anyone gone over the requirements with the client, or are they allowed to invent anything and you're not allowed to offer feedback ?
In any case, you can do this easy enough, just define a column that has a checkbox in a gridview that you display, then check which ones were checked, on postback.
http://www.codeproject.com/info/search.aspx?artkw=gridview+checkbox[^]
There seems to be a lot of CP articles on how to use checkboxes inside a gridview, I'd say you need to start there. It's a while since I've done this sort of thing, and I am sure that an article with downloadable code will help you more than any comments I might make in a forum reply.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Christian,
This is an in-house project and the criteria has already been determined and laid out beforehand.
Thanks again for your quick reply and your help, I really appreciate it. I will check out the information that you provided.
Allison
|
|
|
|
|
Hi Allison,
ahayw01 wrote: I have a check box before each url. The user will need to check off which documents he/she has read and then submit the page.
This is not a good idea in my opinion. Document will be still shown in the documents to read area when user reads the documents and not check off the check box. Automating this would be a nice idea. You can make use of a Http handler and hook one for PDF extension. You only need to show the PDF link to the user without any check box. When user clicks on a PDF file link, this handler will be executed and it will do the logging.
ahayw01 wrote: I can store the document list in a sql database but I am not certain how to maintain the log of documents for each user and how to only display the list of those documents that have not yet been read.
You may need two tables. One for storing the available documents and one for logging the users read activities. Here is a sample.
Master table - Documents<br />
- DocumentId - A unique id to identify each document<br />
- DisplayName - Text displayed to user<br />
- PDFFileName - PDF file name<br />
<br />
Transaction table - UserReadActivity<br />
- UserId<br />
- DocumentId - Foreign key referring Documents table<br />
You can easily get all the documents that a user has to read by using the query
SELECT *
FROM Documents
WHERE DocumentId Not IN (SELECT DocumentId FROM UserReadActivity WHERE UserId = YourUserId); It will be good to show the documents that are already read if user is allowed to reread. It can be achieved by joining the both tables.
Hope that helps.
|
|
|
|
|
Navaneeth,
Thanks for your response. The solution that you proposed is great and automating this makes perfect sense. Unfortunately, I need to be able display the list of documents that need to be read and have the user check the box, confirming that he/she has read the document.
I am sure I will be able to use what you proposed in my future projects.
Thanks again,
Allison
|
|
|
|
|
Create a log table that has it's keys setup to be the userid and the documentid. When they click on the submit button, loop through the checkboxes and add a value (check for duplicates) into this log table. Then, just run a simple query joining your document table with the log table to get those records that have not been viewed.
This is pretty basic coding, so if this is above your head go to the library and get a decent book, there will be many examples on this type of question.
|
|
|
|
|
Hello,
Thank you for your response. Setting up the log table as you suggested makes perfect sense. This seems very feasible and not over my head, so thanks again.
Allison
|
|
|
|
|
Hi everyone,
m trying to understand design patterns .. which one to use when .. most popular ones .. most used in normal projects .. and some good examples ... im tired of vegetables and doctor examples ..
any help would be appreciated
and preferably with code Big Grin
I am also in need of a big project where I can see all the things working together .. that will help a lot in understanding .. if any one can share .. that would be a great help
Thanks
Vishwjeet
|
|
|
|
|
No-one is going to mail you a 'big project'. Your best bet for what you want is to look through the articles here on code project, or perhaps stuff like dot net nuke.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
a small one will do .. but i need some insight on .. what are the most popular design patterns being used for some typical applications nowadays.
like an application for having a custom form for data entry
then reporting using rdlc or maybe a gridview
then having data modification forms .. a very normal application .. but with crucial data
the tutorials on net just tell me what a design pattern is and how to use it
|
|
|
|