-
Continue to end of loop
Hi there Is there some nice way to accomplish the following: WHILE (some condition) THEN BEGIN statement1 IF NOT (statement1 = success) THEN Continue to next turn in the loop statement2 IF NOT (statement2 = success) THEN Continue to next turn in the loop ... And so on ...END; That is some kind of "goto end of loop" or…
-
Lazy Programming: What text-based object files are good for
Source: my blog Last week, I had to do a considerably small change in one of our "Tools". Considerably ... I had to add 4 options to an option field ... and I had to put it in between other option values. First reaction: I don't like that. Second reaction: let's put it at the end to avoid problems (which cascade in other…
-
Barcode Font problem
I have tried to find a solution for this on the forum without success. My apologies in advance if I missed something. My problem is, some clients show a barcode correctly and others show the code *123456*, for example, as if the font is being ignored. I have installed the font Code39 on all clients. Can anyone advise me…
-
Fixing keyboard-shortcuts in NAV thru Citrix
Every developer that has tried to design in NAV via the Citrix ICA-Client have probably been not-so-happy about the fact that the ICA-Client catches a lot of F-keys that NAV uses. Here is a fix to allow Ctrl+F1 (Mark), Ctrl+F2 (Design) and Shift+F12 (Object Designer) to pass the ICA-Client. notepad.exe…
-
Some my thoughts about compress algorithm in NAV
Hi All This my simple single-pass compress algorithm. Of course it not very effective, but it working... :D OBJECT Codeunit 40000 Compress/Expand Mgt.{ OBJECT-PROPERTIES { Date=21-10-08; Time=[11:41:34 ]; Modified=Yes; Version List=; } PROPERTIES { OnRun=BEGIN MESSAGE('Compress ration…
-
Import Objects with C/FRONT.dll (>= NAV 5.01)
Hi, i've tested the new C/Front.dll for NAV 5.01 (5.00 SP1) and i saw there 2 new nice functions. The first nice isExportFOB() the second one isImportFOB() With both you can export / import binary files. So, for example with…
-
Archive sales documents with Amount field defined
This might be usefull for someone. In default NAV, you can archive sales orders (it gets archived, when/if "Order Confirmation" is printed). However, to fully use this functionality, user should firstly release order before printing. I have noticed, that if sales order is not released before printing order confirmation,…
-
How to get server and database name from C/SIDE
Hi, what is a best way to get server address and database name of current connection from C/SIDE (database on SQL)? I found that way://svr Record Server//db Record Databasesrv.FINDFIRST;WHILE NOT srv."My Server" DO srv.NEXT;dbs.FINDFIRST;WHILE NOT dbs."My Database" DO dbs.NEXT;Message(srv."Server…
-
Error during Database restore - access file
We have a Native Navision database (4.01) with 175 companies. I have a complete backup, only 7 companies need to be updated (with most recent transactions done on a backup server). So I took the original database and deleted those 7 companies. Tried to restore 4 so far, 3 companies worked just fine. Forth company ("X"),…
-
How to detect whether a file has been modified
Hey guys, just came up with a question, how to detect whether file has been modified after I open it and close it. I tried to use GETSTAMP but did not get it through. Regards,
-
How to write a CASE statement
Sorry for another newbie post. But just in case I ever forget: CASE TextVar OF 'A' : TextVar1 := 'OMG'; 'B' : BEGIN TextVar1 := 'OMG2'; TextVar2 := 'OMG3'; END; ELSE TextVar1 := 'OMG3';END; If TextVar is an option variable, you would use: CASE TextVar OF TextVar::A : TextVar1 := 'OMG'; TextVar::B : BEGIN TextVar1 :=…
-
how to get Server date?
Navison Install use Client\server, DB is Microsoft SQL, in client , how do i can get Server date?
-
Rollback without visible error message
If you callERROR(''); no error message is shown to the user but the transaction rolls back. You can use it, for example, to run a dataport / xmlport to check if a file is imortable (true no message appears, false you see the error messsage caused by the import).
-
SLEEP that allows automation event-triggers to fire
If you use some automation and want to wait for some event to fire, most of the time you use SLEEP. The problem I found is that SLEEP does NOT allow the event-triggers to fire (at least not the ones I found). So I have invented a method that allows it: I created a function "RealSleep" that allows the event-triggers to…
-
Error on Reportdesign with many Sections
Sometime you must create a Report with many section or must modify a report with many sections. There you will also add new sections like "Header" or Body. As example i will use Report 35 "Document Entries". If you add a new DataItem and you will add for this DataItem new Sections like Header in this Report (35), you get…
-
Get the OptionString of an option field
I don't know if it has been posted before, but today I found this way to retrieve the OptionString values of a field using C/AL code (using NAV 5.0 SP1): Name DataType Subtype LengthmyRecRef RecordRef myFieldRef FieldRef myRecRef.OPEN(18); // Table CustomermyFieldRef := myRecRef.FIELD(39); // Field…
-
Read optionstring directly from SQL Server table
Hi, I'm working on an external .NET application to show some data from Navision tables by accessing the SQL Server. If the table has an OptionString field, I would get an integer instead of the string representation. Does anyone know where this string information is stored in SQL Server? Currently I'm using enum to map the…
-
record assignment vs TRANSFERFIELDS
if one needs to assign fields from one record SrcRec to another DestRec of the same table one can use assignment operator: DestRec := SrcRec i just wanted to point that these two are not identical - as a side effect assignment operator changes the company DestRec record is working with to the one SrcRec is working with…
-
Getting Rid of Escape Jumping you to the wrong Menu Pane
Ever since 4.0 there is a MenuSuite "feature" that has really annoyed me. If you open a form from one menu pane, then click on a new menu pane, then close the form, you jump to the original menu pane. Beneath all of the MenuSuite buttons, to the left of the little arrows, right click the mouse. Select Navigation Pane…
-
Navision Team Development on SQL Server
One of the issues with working on server in Navision with other developers is that objects get overwritten. I've written a tool that prevents this from happening. This works on SQL 2005 only. It is written in .NET sql CLR. I've blogged out it in here http://mibuso.com/blogs/ara3n/2008/05/1 ... elopement/ Download the zip…
-
How to identify selected rows
Is is possible to identify the currently selected rows in a grid on a form? I want the user to select a few rows with shift.click and to then click on a button to perform an action on those rows. I thought it might be the Markedonly function but it doesn't appear to do what I want.
-
Getting Rid of Escape Jumping you to the wrong Menu Pane
girish.joshi over at dynamicsuser.net has just posted something which changes one of the more annoying features in NAV. http://dynamicsuser.net/forums/p/23541/ ... spx#123146
-
Print report to different printers
Hi All I need ideas on how to print the same report to two different printers. Basically I have a button, that when clicked I need to send the same report to multiple printers. I would not like to create two objects numbers to use the Navision printer selections table, so if anyone has a better idea I would appreciate.…
-
Compare 2 fields in same table for filtering
A lot of times you want to filter records WHERE FIELD1 = FIELD2, but in Navision this is not possible. You need to read all records and then select the ones you need. With the help of a flowfield in the table, this can be done: Example table 99999:"TheTable": 10:"KeyField" : any type 100:"FIELD1" : any type 110:"FIELD2" :…
-
How can we define null duration datatype?
Hi all, If time is null then we can define as 0T DATE IS NULL then we can define as 0D how can we define duration if it is null thanks& regards: lakshman
-
Import data from .docx
Hi, Is it possible to import data from a word document into a navision 5.0 table ? If so, how do i do it ! thank you ALL
-
How to set up Email Logging in 5.0
There is a new knowledgebase article on this. You can find it here.
-
NAV Form Control update. (Redraw)
Well first off I'm not even sure if anyone else experiences this issue. I see no posts on it, and previously when I had asked for a remedy on this issue no one really responded. So I have to ask, "Am I the only one experiencing an intermittent issue involving enabling / disabling control(s) at Runtime. Where the control(s)…
-
Funny things with reports
I don't know the way this can be useful but...I'd like to tell you, maybe you'll find a way. -Export a report (with some sections) in txt format. -reduce sectionheight parameter amount in order to make it less than the height of the controls contained (you are not able to do it in NAV) -Import and compile -print :shock:…
-
How to Count No. of Months?
Hi Experts, I am working on the Cust. Ledger Entry table trying to design the customer Balance to date report. My problem is i want to count the No. of months from the Posting dates so that i can get the no. of months that are paid in the report. The posting dates Correspond to the payments made. I need Assistance in this…