-
Tips & tricks the server name and the db one
Output text with information of the server name and the db one (using Confirm(varTxt)) in trigger OnQueryCloseForm of the MainMenu So in order to find out the db info just press 2 keys: F12 then ESC from any form. (c) :lol:
-
cycle in NAT Tips&Tricks
//If you need to execute cycle without table (for example in report) //you should make next: //in trigger OnPreReport kk := 0; REPEAT kk += 1; // - your operators ... ... // - your operators IF (something) THEN EXIT; UNTIL kk = 1000;
-
Export Table Data
Do you want to quickly export all the data form a specific table (also from system tables) ? Here is a function ExportTableData Parameters:* liTableID (Integer): ID of Table to export Data * lbWithFlowFields (Boolean): Calculate and export also FlowFields * lbWriteFieldID (Boolean): Write Header Row with Field IDs (Field…
-
Resetting automation controls
Alright, here's a hard lesson learned... I had some issues with the Outlook integration, where my codeunit 5072 (outlook application management) still didn't compile after registering the new versions of the dll's. So, after a long time, I finally discovered which one is supposed to be the OLHandler automation server. What…
-
Dataport and date formats...
In a dataport to export to a MySql format the next code in the OnAfterFormatField trigger allow convert the date in the right format : Text := STRSUBSTNO('%3-%2-%1',COPYSTR(Text,9,2),COPYSTR(Text,6,2),COPYSTR(Text,1,4)); To import from a MySQL format use the code in the OnBefoirEvaluateField : IF Text = '2000-00-00' THEN…
-
Functions Parameters by ref / by val
Using Navision functions can you pass parammeters like in VB by val or by ref ?
-
Navision Trianining
Does anyone know why the navision training is not working. today., Oct. 29, 2003 www.training.navision.com Thanks Francisco
-
Version 3.xx CASE on ranges
Version 3.xx does still allow to use a range as a CASE test For example the following code works in both Navision Attain 3.10A as well as Microsoft Business Solutions - Navision 3.7. VAR a : Integer; CASE a OF 1..10 : MESSAGE('Test 1'); 11..15 : MESSAGE('Test 2'); 16..17 : MESSAGE('Test 3'); END; I have had no problems…
-
How to use the sign & in a Captionfield
If you need to show the text "Tips & Tricks" in a captionfield you have to write it like this "Tips && Tricks". Otherwise the &-sign will make an underscore.
-
Update your file record.
Hi, To update your FILE record in Navision, set a different filter and find something, anything. After that you can reset (set again) your filters and your record is updated. Sample files.setrange(path, 'c:\foo\bar\');repeat if files.find('-') then movefile; until foo = bar; The find will ALWAYS find the same file. Change…
-
Open any table lookup form without define any form variable
Maybe you know this feature, maybe not... You could run the form specified in LookUpForm property of a table from any object without define any variable with datatype Form i.e. if you have a RequestForm to select Payment Methods for filtering a DataItem in a report, just create a global variable like this Name: rec289…
-
report as E-Mail NF 2.6b
How can i send a Report as an e-Mail and what is the best fax-sollutions alex
-
Excel Worksheets
Hi there... I am currently encountering problems attempting to add a new worksheet after the current end worksheet in Excel. The parameters are: [lDISPATCH Add:=]Add [VARIANT Before][,VARIANT After][,VARIANT Count][,VARIANT Type] And then the help file kindly gives me the following example... ActiveWorkbook.Sheets.Add…
-
Renumber field numbers in a table...
Renumber field numbers in a table… Renumbering fields in a table is a b… But here is a simple way to do it fast, simple and without any errors. Export all object related to the table, in witch the field is that you want to renumber, as text. If you don’t know the related objects, export them all. Import them again. All the…
-
HYPERLINK instead of SHELL
You can open a WinWord-Document within Navision with the SHELL-statement such as .. SHELL ('C:\Office\WinWord.EXE D: \Documents\Navision\MyDocument.doc); But you can achieve the same with the Hyperlink statement: hyperlink('D:\Documents\Navision\MyDocument.doc'); Of course this works with all registered document types:…
-
Conversion: time to integer
If you want to express your time in milliseconds, and you do the following: INTEGER:=TIME; you will get an error: it's not possible. But.. if you do it like this: INTEGER:=TIME-000000T; it will work!!
-
Version 3.xx CASE on ranges
In NF you can write a statement like CASE a OF 1.. 10 : BEGIN END 11.20 : BEGIN END; END This is not possible in version 3.xx, however, you can circumvent it by using the below construction CASE TRUE OF (a > 0 AND a < 11): BEGIN END; (a > 10 AND a < 21) : BEGIN END; END; The first TRUE statement will be executed, however…
-
Cut&Paste in Source Expression
As you know, you can open the a List of C/AL Expressions with F5 on the SourceExpression Property. Unfortunately you cannot insert a variable directly in the SourceExpression by selecting a variable and pressing <Enter>. However you can Copy the variable with Ctrl-C in the List and paste it with Ctrl-V in the…
-
Input Dialog
You need the user enters some parameters but you don't want to create a form for it: Let's ask for three dates within our codeunit: Var window : Dialog; BookingDate : Date; DocumentDate : Date; DeliveryDate : Date; EntryNo : Integer; NewEntryNo : Integer; Window.open ('Booking Date #1#########\'+ 'Dok. Date #2#########\'+…
-
Report: Print Options from Request Form
On the Request Form you define variables like layout, number of copies, etc. Now you want to print these options. Simply Copy/Past the fields from the RequestForm to the sections. It is also possible to copy/paste normal fields and even buttons from forms into the report sections. Marcus Fabian m.fabian@thenet.ch +41 79…
-
Dataport Requestform
By default, Dataports let you select the Import/Export filename. However, as soon as you use the RequestForm this Filename-Field disappears. If you want both, RequestForm and Filename do the following: 1) Define a global Variable "Test" 2) Insert a Textbox with SourceExpression "Test" 3) Set the AsistEdit property to "yes"…