Set Page fields Visible & not Visible during runtime??
Votuc
Member Posts: 206
Hi,
I know I started a similar post but I don't think I explained my problem in the right words.
I want to know if it is possible to set fields on a PAGE visible and not visible based on the TYPE of record I am viewing. I want to do this while moving through the records by clicking the "next record" action from the action menu.
So: view one type of records.... fields 1-8 visible......move to next record (of different type based on condition) and now set fields 1-8 NOT visible and set fields 9-15 visible instead.
Is this possible?
I tried setting the field visible property to a boolean variable called isvisible. Then under the properties of isvisible, I set "include in dataset" to yes. Then I had a function to test the condition I want and set the variable isvisible to true --- like so:
if condition is met....
isvisible = true;
currPage.update(false);
But it does not work.
None of the fields visible property changes.
I know I started a similar post but I don't think I explained my problem in the right words.
I want to know if it is possible to set fields on a PAGE visible and not visible based on the TYPE of record I am viewing. I want to do this while moving through the records by clicking the "next record" action from the action menu.
So: view one type of records.... fields 1-8 visible......move to next record (of different type based on condition) and now set fields 1-8 NOT visible and set fields 9-15 visible instead.
Is this possible?
I tried setting the field visible property to a boolean variable called isvisible. Then under the properties of isvisible, I set "include in dataset" to yes. Then I had a function to test the condition I want and set the variable isvisible to true --- like so:
if condition is met....
isvisible = true;
currPage.update(false);
But it does not work.
0
Comments
-
Is the version R2? I read about the same problem in R2 here in another thread. It seems like in R2 you can only set visibility on a Group not on a field. I haven't tried it myself but you could try wrap a group around the field and set that ones visibility as a workaround.0
-
Votuc wrote:I tried setting the field variable to a boolean variable called isvisible. Then under the properties of isvisible, I set "include in dataset" to yes. Then I had a function to test the condition I want and set the variable isvisible to true --- like so:
if condition is met....
isvisible = true;
currPage.update(false);
But did you actually set the Visible property on each of the text boxes?0 -
matttrax wrote:
But did you actually set the Visible property on each of the text boxes?
Hi, sorry I meant to say I set the field property "visible" as a varible called isvisible instead of true/false. I was using this post as an example: http://www.mibuso.com/forum/viewtopic.php?f=32&t=33236&hilit=visiblE+property+in+RTC0 -
i think the problem is the same as here :-k
http://www.mibuso.com/forum/viewtopic.php?f=32&t=460370 -
@Votuc:
As DeV.ch said
the visibility property will work on Groups.It seems like in R2 you can only set visibility on a Group not on a field.
As per your requirement, set 1-8 fields in Group1 and 9-15 in Group2.
Create a Boolean(IsgrpVisible) variable and set IncludeInDataset to Yes
Write IsgrpVisible = (your condition) in OnOpenPage() and OnAfterGetRecord()
Set Group Visible = IsgrpVisible
It will work while moving through the records by clicking the "next record" action from the action menu.
If you want it in field wise in same group, you can assign boolean variable to visible property of field but it will work only you open the Record not while moving through the records by clicking the "next record" action from the action menu.0 -
Thank you everyone for your suggestions. I will try the group suggestion and report back to this thread.0
-
Hello Everyone..
I have created Page With Many Fields.For Some Filter I have to Show only particular Field among all fields in RTC
I have Created two Function
1) First Which Hide all Fields.
2) Second Which Visible Field base on Filter
I have Created Boolean Variables with "IncludeDataSet = Yes"
"OnInit" Trigger
Test1 := True
OnOpen Trigger
Test1 := False
Resource Filter Trigger
{
}
On Resource Trigger I am Passing Value of That Field on this basis i have to show that field
but This is not Working
Anyone Can help me
Thanks.........0 -
jigneshdhandha wrote:Hello Everyone..
I have created Page With Many Fields.For Some Filter I have to Show only particular Field among all fields in RTC
I have Created two Function
1) First Which Hide all Fields.
2) Second Which Visible Field base on Filter
I have Created Boolean Variables with "IncludeDataSet = Yes"
"OnInit" Trigger
Test1 := True
OnOpen Trigger
Test1 := False
Resource Filter Trigger
{
}
On Resource Trigger I am Passing Value of That Field on this basis i have to show that field
but This is not Working
Anyone Can help me
Thanks.........
Hi,
The Visible property only works in OnOpenPage and OnInit trigger, so after open the page in runtime is not posible to modify the property.
The properties Enable and Editable works perfectly :thumbsup:
In Nav 2013 the property Visible works also ok! =D>
Regargs.0 -
Thanks JaJ....0
-
Hi,
I hope it ll work your condition placed in on after get record and on after get curr record Trigger also.
I have tried its working perfectly
Mani.0 -
Which version are you using?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
- 610 NAV Courses, Exams & Certification
- 1.9K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 251 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

