ZUP-file Management

Administrator
Member, Moderator, Administrator Posts: 2,506
ZUP-file Management
Have you ever spend minutes trying to explain a user how to delete his/her zup-file??
These functions can be used to 'clear' the zup-file if problems have occurred. All done by the user him-/herself by selecting a menuitem!
The zup-file will be re-initialized to a default state determined by the programmer implementing the codeunit.
Feel free to use my code as you will.
If you have the time it is farely simple to save the zup-file as a blob or as values in a table, so you can store several zup-files to choose from instead of just an empty one.
http://www.mibuso.com/dlinfo.asp?FileID=892
Discuss this download here.
Have you ever spend minutes trying to explain a user how to delete his/her zup-file??
These functions can be used to 'clear' the zup-file if problems have occurred. All done by the user him-/herself by selecting a menuitem!
The zup-file will be re-initialized to a default state determined by the programmer implementing the codeunit.
Feel free to use my code as you will.
If you have the time it is farely simple to save the zup-file as a blob or as values in a table, so you can store several zup-files to choose from instead of just an empty one.
http://www.mibuso.com/dlinfo.asp?FileID=892
Discuss this download here.
0
Comments
-
Interesting, although instead of trying to explain anything I've always solved it by putting a BAT file on their desktops saying del "C:\Documents and Settings\%USERNAME%\Application Data\fin.zup"
(Don't remember the correct path off the top of my head but the main point is the %USERNAME% trick)
Anyway, this solution is way more elegant, so thanks a lot!0 -
Miklos, Thank you for the nice words.
I am normally only using the ID parameter, so I missed managing the use of other parameters.
An update has just been uploaded. (Thanks to AVP for 'correcting' my code)loctxtFilename := COMMANDLINE; IF STRPOS(UPPERCASE(loctxtFilename), 'ID=') = 0 THEN loctxtFilename := 'fin.zup' ELSE BEGIN loctxtFilename := COPYSTR(loctxtFilename, STRPOS(UPPERCASE(loctxtFilename), 'ID=') + 3); IF STRPOS(loctxtFilename, ',') > 0 THEN loctxtFilename := COPYSTR(loctxtFilename, 1, STRPOS(UPPERCASE(loctxtFilename), ',') - 1); IF STRPOS(UPPERCASE(loctxtFilename), '.ZUP') = 0 THEN loctxtFilename := loctxtFilename + '.zup'; END; IF STRPOS(loctxtFilename, ':') = 0 THEN BEGIN loctxtPath := ENVIRON('USERPROFILE'); IF COPYSTR(loctxtPath, STRLEN(loctxtPath), 1) <> '\' THEN loctxtPath := loctxtPath + '\'; loctxtPath := loctxtPath + 'Application Data\' + loctxtFilename; END ELSE loctxtPath := loctxtFilename;
0 -
ZUP-file Management
Have you ever spend minutes trying to explain a user how to delete his/her zup-file??
These functions can be used to 'clear' the zup-file if problems have occurred. All done by the user him-/herself by selecting a menuitem!
The zup-file will be re-initialized to a default state determined by the programmer implementing the codeunit.
Feel free to use my code as you will.
If you have the time it is farely simple to save the zup-file as a blob or as values in a table, so you can store several zup-files to choose from instead of just an empty one.
UPDATE 2007-09-17:
Update to allow for other parameters. Thanks to AVP.
http://www.mibuso.com/dlinfo.asp?FileID=892
Discuss this download here.0 -
Great Tool!
(I added the procedures to my private Tools DB with credits for you and a link to this topic.)
Please note that the path name for 'Application Data' can change from country to country.
In a german Windows installation it is named 'Anwendungsdaten', so you should use a TextConst or use 'APPDATA' instead of 'USERPROFILE'.
Furthermore you check the path for ':' which means that the zup file must be stored on a local HDD.
It doesn't make sense but it is possible that there is entered an UNC path like \\Server\Share\Folder\Fin.zup
I suggest that you check for '\' instead of ':'IF STRPOS(loctxtFilename, '\') = 0 THEN BEGIN loctxtPath := ENVIRON(APPDATA); IF COPYSTR(loctxtPath, STRLEN(loctxtPath), 1) <> '\' THEN loctxtPath := loctxtPath + '\'; loctxtPath := loctxtPath + loctxtFilename; END ELSE loctxtPath := loctxtFilename;
Timo Lässer
Microsoft Dynamics NAV Developer since 1997
MSDynamics.de - German Microsoft Dynamics Community - member of [clip]0 -
Thanks Timo - changed that too!
New file uploaded.0 -
ZUP-file Management
Have you ever spend minutes trying to explain a user how to delete his/her zup-file??
These functions can be used to 'clear' the zup-file if problems have occurred. All done by the user him-/herself by selecting a menuitem!
The zup-file will be re-initialized to a default state determined by the programmer implementing the codeunit.
Feel free to use my code as you will.
If you have the time it is farely simple to save the zup-file as a blob or as values in a table, so you can store several zup-files to choose from instead of just an empty one.
UPDATE 2007-09-18:
Update to use APPDATA instead of USERDATA and search for '\' instead of ':'. Thanks to Timo.
UPDATE 2007-09-17:
Update to allow for other parameters. Thanks to AVP.
http://www.mibuso.com/dlinfo.asp?FileID=892
Discuss this download here.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