x++


Reading a comma separated values (csv) file in dynamics ax


How do you open and parse a csv file in dynamics ax?
static void TestCommaTextIO(Args _args)
{
#File
CommaTextIo commaTextIo;
FileIOPermission permission;
container containFromRead;
int x;
int cols;
;
permission = new FileIOPermission('c:\\junk\\mycsv.csv',#io_read);
permission.assert();
commaTextIo = new CommaTextIO('c:\\junk\\mycsv.csv','R');
containFromRead = commaTextIo.read();
While(containFromRead)
{
cols = conLen(containFromRead);
for(x=1;x<=cols;x++)
{
print conpeek(containFromRead,x);
}
containFromRead = commaTextIo.read();
}
pause;
commaTextIo = null;
}

Related Links

Set a Date Value to a Date Field in AX2012
Determine if a job is running in X++ code
Dynamics AX 2012 parsing Int32 to table field integer
Cancel Sales order packing slip through x++
Transferring open account records between customers
How to make sure that a form is only opened once?
Extend system menu in Dynamics AX 2012?
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

Categories

HOME
httparty
kentico
cobalt
checkstyle
spark-streaming
pda
pyqt
case
socket.io
access
rds
iis-6
azure-container-service
mautic
spring-social
libc
screen-readers
keytool
linear-algebra
event-sourcing
intershop
solrcloud
ag
rubymotion
cgbitmapcontext
ios10.2
short-url
direct3d11
windows-server-2003
spotipy
vex
panoramas
complex-numbers
sendbird
installscript
baidu-map
xdocreport
node-mssql
odroid
loading
metaprogramming
opensmpp
chef-solo
magento-1.9.3
plaintext
sharp-snmp
microsoft-metro
glm-math
dbcontext
lightning
google-cse
trojan
payara-micro
pdf-conversion
rmongo
winusb
preprocessor
nikeplus-api
vorpal.js
query-by-example
upx
fuzzywuzzy
design-principles
wiredep
jdi
ons-api
.bash-profile
omnifaces
qtwebengine
crowd
alternate
radiant
drupal-nodes
rolify
nebula
intersect
midlet
uimanageddocument
xcode3.2
subgraph
expression-blend-4
promotion-code
rmdir
resharper-6.0
ie-compatibility-mode
easyb
aspmenu
murmurhash
lxr
firefox-3
image-capture

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