Page's controls problem

Troubles_In_Paradise
Member Posts: 588
Hi Guys! I need your help for a problem with a page.
I've a page with this structure:
in the OnOpenPage I put this code:
the problem is on the else part of the test... in fact as you can see from the code I put 2 messages at the end of the else and they show me exactly what I expect (so I think code is right) but the page doesn't print anything...
anyone could give me any suggestions?
Thx in advance!
I've a page with this structure:
ContentArea Repeater field - RespCenterCode field - RespName
in the OnOpenPage I put this code:
RecordUserSetup.RESET; RecordUserSetup.GET(USERID); IF RecordUserSetup."Sales Resp. Ctr. Filter" = '' THEN BEGIN RecordSession.SETRANGE("My Session",TRUE); IF RecordSession.FINDFIRST THEN BEGIN RecordUserSession.RESET; RecordUserSession.SETRANGE("Connection No.",RecordSession."Connection ID"); IF RecordUserSession.FINDFIRST THEN BEGIN RespCenterCode := RecordUserSession."Responsibility Center"; RespCenterCode.RESET; RespCenterCode.GET(RespCenterCode); RespName := RespCenterCode.Name; MESSAGE(FORMAT(RespCenterCode)); MESSAGE(FORMAT(RespName)); END; END; END ELSE BEGIN RespCenterCode.RESET; IF RespCenterCode.GET(RecordUserSetup."Sales Resp. Ctr. Filter") THEN BEGIN RespCenterCode := RespCenterCode.Code; RespName := RespCenterCode.Name; MESSAGE(FORMAT(RespCenterCode)); MESSAGE(FORMAT(RespName)); END; END;
the problem is on the else part of the test... in fact as you can see from the code I put 2 messages at the end of the else and they show me exactly what I expect (so I think code is right) but the page doesn't print anything...
anyone could give me any suggestions?
Thx in advance!
~Rik~
It works as expected... More or Less...
It works as expected... More or Less...
0
Answers
-
the number of records in a repeater depends on the filtered records of the source table. If there's no sourcetable, you have no records, no matter what you want to print.
If you have a sourcetable, be sure that it contains at least one record.
If you don't have it you can use "integer" as sourcetable, and filter it only for number = 1.0 -
Thx for reply!
The Source Table is "User and Session"~Rik~
It works as expected... More or Less...0 -
Troubles In Paradise wrote:Thx for reply!
The Source Table is "User and Session"
Have you checked is there any records in this table?--
Regards,
Raveendran.BS0 -
Yes there's one record that shows me the user and his Responsibility Center~Rik~
It works as expected... More or Less...0 -
Hi Guys! Solved!
I must say sorry to you because when I said that there was a record in the sourcetable I was wrong :oops:!
In fact in codeunit 1 there was a personalization that deleted record in my sourcetable.
Since I can't delete this personalization Belias suggest me 2 solutions:
- use an integer sourcetable as you can read above
- use a temporary sourcetable, insert the value that I want to see in this temporary table and then show the 2 fields just inserted
Thx all for help!~Rik~
It works as expected... More or Less...0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K 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
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions