Home » Developer & Programmer » Forms » using check box dynamically at runtime
using check box dynamically at runtime [message #145099] Mon, 31 October 2005 19:58 Go to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
To the person who posted the 'how to select between two check/tick boxes' my apologies for deleting your thread.

If you have two list of checkboxes then find the checkbox from each list, apply the value to a new select clause for your main query block, use the set_block_property('blk',default_where,'your select statement'). Have look at the example in the Pre-Query trigger documentation. Then perform your Execute_Query command.

David
using check box dynamically at runtime [message #145135 is a reply to message #145099] Tue, 01 November 2005 01:52 Go to previous messageGo to next message
elile_gregory
Messages: 1
Registered: October 2005
Junior Member
How do I make a check box programmatic in that when two values are selected the values between them will also be specified. I would like to eliminate the manual process of having to tick each box concern

For example if I have a form that looks like this
Check box column	Item column	Another item column
	Dbr300	                         Item description 
	Dbr301	                         Item description 
	Dbr302	                         Item description 
	Dbr303	                         Item description 
	Dbr304	                         Item description 
	Dbr305	                         Item description 
	Dbr306	                         Item description 
	Dbr307	                         Item description 
	Dbr309	                         Item description 
	Dbr310	                         Item description 
	Dbr311	                         Item description 
	Dbr312	                         Item description 
	Dbr313	                         Item description 
	Dbr314	                         Item description 
	Dbr315	                         Item description 
	Dbr316	                         Item description 
	Dbr317	                         Item description 
	Dbr319	                         Item description

I would like to create a form that when the users ticks dbr300, then user ticks on dbr319 all the values between this two item automatically is selected. I would like to eliminate the process of ticking all the values one by one……………..please can someone help

Upd-mod: Add code tags

[Updated on: Tue, 01 November 2005 16:39] by Moderator

Report message to a moderator

Re: using check box dynamically at runtime [message #145245 is a reply to message #145135] Tue, 01 November 2005 23:51 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Sorry to be so long in getting back to your question. I will be brief.

Use the :system.mouse_button_shift_state and :system.mouse_button_modifiers settings to determine whether the 'shift' or 'control' keys have been held down when the mouse is 'clicked'.

Behaviour: When user 'clicks' a box and neither 'control' or 'shift' is held down then all 'checked' boxes are 'unchecked' and this box is 'checked'. If the 'mouse_button_shift_state' (read the doco) is 'Shift+' then check this box then find the previous 'checked' box and 'check' all the boxes in between them. If the 'mouse_button_shift_state' is 'Ctrl+' then just 'check' this box (without 'unchecking' any other box).

David
Re: using check box dynamically at runtime [message #145308 is a reply to message #145135] Wed, 02 November 2005 06:47 Go to previous messageGo to next message
kiran
Messages: 503
Registered: July 2000
Senior Member
Just to add , Once after you define whether the user Checked using "Shift" (or) "Ctrl" , Then by using "WHEN_CHECKBOX_CHECKED" Trigger , and CHECKBOX_CHECKED built-in functions you can check the checkboxes.

--Kiran.
Re: using check box dynamically at runtime [message #145397 is a reply to message #145308] Wed, 02 November 2005 17:58 Go to previous message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Actually, you do ALL the checking inside the When-Checkbox-Changed.

And I should have said that when 'Control' is held down you 'toggle' the checkbox not just set it 'checked'.

David
Previous Topic: Popup when form is opened.
Next Topic: output from Tlist concatinated???
Goto Forum:
  


Current Time: Fri Sep 20 03:31:32 CDT 2024