x++


X++ loop through lines in grid control


So the idea is to assign an icon to a Window control in the Grid control of a form (PurchTable), depending on whether a record has a document attached to it.
I use a select statement to check DocuRef if there is match between RefRecId and current RecId.
So the question is, how do I assign a different icon to each line? Can't really figure it out :/
I'm guessing you wrote a display method similar to method showDocHandIcon on table InventTestGroupMember. In that case, you need to return an icon resource number depending on some data of your current line.
So for example your lines contain an enum field and the enum has three values 1, 2 and 3 and for values 1 and 2 you want to return icon 1 and for value 3 you want to return icon 2.
Btw, you wrote that you check if there is a match between RefRecId and RecId. Please consider also checking refDataAreaId and refTableId, since the RefRecId may not be unique in table DocuRef.

Related Links

How to show selected items of certain table on the different table in Dynamics AX 2012?
AllowEdit doesn't work properly in Dynamics AX
AX 2012 how to set args record datasource in X++
Clients seem to be running old (buggy) code after XPO project import
Number sequence AX 2012
SSRS MS words report with page break
How can you get a detailed error descriptions in Dynamics AX?
How to get the length of an array?
X++ loop through lines in grid control
Concatenating row values in x++
How do you access a macro in the AOT macro node?
How can I set the Backgoundcolor of an AX2012 Action Pane Button
How to Edit address using X++ in AX 2012
Number sequence issue Ax 2012?
Find code that's running in a Batch Job
What is the _isMexican boolean for in the Global::Checkpower method?

Categories

HOME
sonarqube
wakanda
3d
mapbox
accessibility
startup
resultset
opengl-es-3.0
spring-social
stellar.js
3nf
flatpak
libusb
easyphp
html5-appcache
cfml
topology
drive
cgbitmapcontext
systemtime
gmock
data.stackexchange.com
pic32
delimiter
fractions
failover
erb
android-sugarorm
github3.py
vue-chartjs
installscript
numpy-broadcasting
docfx
gdata
jvmti
xv6
logback-groovy
rfc3339
mschart
netbeans6.8
remedy
scalding
oracleclient
seq
renaming
javafx-css
cubism.js
x-tag
toran-proxy
roadkill-wiki
flock
canalyzer
lasso
vacuum
haskell-warp
botan
teamcity-9.1
fail2ban
at-job
viewer
insight.database
personalization
codeplex
jquery-slider
dot42
ecslidingviewcontroller
code-duplication
inputmismatchexception
hidapi
inappsettingskit
android-icons
composite-component
traceability
server-administration
cardreader
http-status-code-410
web-notifications
android-loadermanager
frameworkelementfactory
patricia-trie
jquery-blockui
fitbounds
box2d-iphone
massive
collectionviewsource
photolibrary
wcf-instancing
sqlobject

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App