Solved

display a DTC databound checkbox in a DTC

Posted on 2002-05-31
1
238 Views
Last Modified: 2013-12-24
How do I display a DTC databound checkbox in a DTC datagrid?
Thanks
0
Comment
Question by:revman
1 Comment
 

Accepted Solution

by:
begaj earned 100 total points
ID: 7341259
revman,

you will have to use some script to do this:

In one of the columns of the datagrid enter hidden field to hold absolutePosition for each record. i.e.

"<input type=hidden name=abspos value=" + Recordset1.absolutePosition + ">"

In the column that you want to display checkbox put a function something like this:

=WriteCheckBox([JobDone], Recordset1.absolutePosition)

and the function should look something like:

<script LANGUAGE="vbscript" RUNAT="Server">
     Function WriteCheckBox(txtCompleted, numPos)
          Select Case txtCompleted
               Case "ON"
                    CheckBox = "ON"
               Case "OFF"
                    CheckBox = "OFF"
          End Select
         
          OutVal = "<input name=Completed" & numPos & " type=checkbox  value="" & CheckBox & "">&nbsp;"
         
          WriteCheckBox = OutVal
End Function

To update recordset use a function which you call using a button or on any event (i.e.thisPage.onenter()) and check if the field value is different to checkbox value.

Long time since I've done this (and I've used radio buttons) so it might need twiking. Hope this helps.

Enjoy!
0

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

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

Introduction In this tutorial, I'll explain how to create an animated progress meter in a wireframe prototype developed using Axure RP 7.0 - a leading prototyping tool for designing web sites and software. (For more information about Axure and gett…
This guide will walk you through the essential considerations and tech stack for building scalable websites. Know how to grow your business the smart way!
The purpose of this video is to demonstrate how to reset a WordPress password if you are locked out and cannot reset the password. A typical use would be if you cannot access the email to which WordPress would send the password recovery email to…
The purpose of this video is to demonstrate how to set up an RSS Feed on a WordPress Website. This will be demonstrated using a Windows 8 PC. Feedburner will be used for this demonstration. Go to your WordPress login page. This will look like the…

932 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now