Checkbox doesn't have the OnFormat trigger?
NaviDev
Member Posts: 365
Hello,
I have this form with a table box control. Inside the table box are textboxes and radioboxes. I have modified the OnFormat triggers of the textboxes to put forecolors on it, but why is this radiobox doesnt have the OnFormat trigger? What I want actually is to have the a higlighted line when and where ever i put my cursor. I know the logic on how to do it in textboxes. But too bad not in radiobox. Please suggest me what to do.
Many Thanks in advance.
I have this form with a table box control. Inside the table box are textboxes and radioboxes. I have modified the OnFormat triggers of the textboxes to put forecolors on it, but why is this radiobox doesnt have the OnFormat trigger? What I want actually is to have the a higlighted line when and where ever i put my cursor. I know the logic on how to do it in textboxes. But too bad not in radiobox. Please suggest me what to do.
Many Thanks in advance.
Navision noob....
0
Comments
-
:-k a radio button makes no sense in a list box. Which option should it display?
So, if you have options and you will display the options in the list form, use a tesxtbox. Now you have also the OnFormat() Trigger.
RegardsDo you make it right, it works too!0 -
Sorry, i was already confused :shock: . I dont mean radioboxex, its checkboxes.Navision noob....0
-
You sound surprised that there is no OnFormat event for a checkbox. How do you want to format a checkbox?0
-
Hello Sir DenSter,
What I want is to have forecolor on the active line in that checkbox control.Navision noob....0 -
-
No. I want a color(something to highlight) the active line(where the cursor). ThanksNavision noob....0
-
Do you mean something (the style) like this :?:
But a checkbox can't be colored or selected. So, if you really need it, us a textbox for your bool variable.Do you make it right, it works too!0 -
Yes like those lines. But why is it that in the checkbox is it not highlighted?Navision noob....0
-
NaviDev wrote:Yes like those lines. But why is it that in the checkbox is it not highlighted?
Because a checkbox has no OnFormat() ;-)
So, if you really need it, us a textbox for your bool variable, then u have the OnFormat trigger
RegardsDo you make it right, it works too!0 -
Seems like I have no choice.

But how about for the picture box? I also use them inside my tablebox. I cannot use a textbox as a replacement for the picturebox. Is there anyways for picturebox?Navision noob....0 -
If the field doesn't have to be editable, then there is a way to simulate a checkbox using a textbox.
Make a function Formatboolean, input parameter a boolean ( i call it "value" in the following code ). Returns a text with length 1if value then exit('a') else exit ('') ;
Then add a textbox to your table, set the sourceexpression to "FormatBoolean(<your boolean value>)" and set the font of that field to Marlett ( you might have to fiddle with the fontsize a bit ).0 -
Hi MBerger,
That is a nice trick! \:D/
If you put this in the OnFormat trigger of the textbox you can even filter on it:IF Text = FORMAT(TRUE) THEN Text := 'a' ELSE Text := '';
Reijer Molenaar
Object Manager0 -
To be clear, make a textbox with the following properties.
Then you can filter on the boolean field with F7.{ 1100512006;TextBox;1482 ;2860 ;1700 ;440 ;Editable=No; ParentControl=1100512000; InColumn=Yes; HorzAlign=Center; FontName=Marlett; FontSize=10; DropDown=No; SourceExpr="Boolean Field"; OnFormat=BEGIN IF Text = FORMAT(TRUE) THEN Text := 'a' ELSE Text := ''; END; }Reijer Molenaar
Object Manager0 -
Thanks. Same trick can be used on reports too !reijermolenaar wrote:Hi MBerger,
That is a nice trick! \:D/0
Categories
- All Categories
- 75 General
- 75 Announcements
- 66.7K Microsoft Dynamics NAV
- 18.8K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 611 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 253 Dynamics CRM
- 103 Dynamics GP
- 6 Dynamics SL
- 1.5K Other
- 991 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 28 Design Patterns (General & Best Practices)
- Architectural Patterns
- 9 Design Patterns
- 4 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1K General Chat
- 1.6K Website
- 77 Testing
- 1.2K Download section
- 23 How Tos section
- 249 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions

