Hi Gurus,
I have to export data into the text file using Dataport and need to store that text file into the User's My Document Folder.
Any one help me to find the path (My Documents for Different User's).
Urgent... ](*,)
Thanks
Veerendra CH.
Veerendra Ch.
http://midynav.blogspot.com/ (
Microsoft
Dynamics
Navision)
0
Comments
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
use env. variable HOMEPATH,
to get drive letter for that dir use HOMEDIR.
to get location of My documents dir, you'd have to look into registry:
I think the key is:
\HKEY_CURRENT_USER\software\microsoft\windows\currentversion\explorer\shell folders\personal
Adding My Documents after HOMEPATH is not always correct, because user may change the location of My documents folder and in different win languages My documents is also translated.
Its working Fine...
I have used
Path := ENVIRON('USERPROFILE') + '\My Documents\' + 'Textfile001.txt';
=D>
http://midynav.blogspot.com/ (Microsoft Dynamics Navision)
see registry "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders\Personal"
How to read from registry - search MIBUSO.
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.