Ir al contenido principal

Entradas

Mostrando entradas de enero, 2019

The F_FIC_TRACE it’s a function tha return the full path of the trace

Funprog F_FIC_TRACE ( XGTRACE ) Value Char XGTRACE Local Char WNAME ( 250 ) If left$ ( XGTRACE , 2 ) = "#@" & ( GBROWS | GSERVEUR ) WNAME = "" Elsif max ( instr ( 1 , XGTRACE , "/" ) ,instr ( 1 , XGTRACE , "\"),instr(1,XGTRACE," @" ) ) WNAME = XGTRACE Else WNAME = filpath ( "TRA" , XGTRACE , "tra" ) Endif If filinfo ( WNAME , 0 ) = 0 WNAME = "" Endif End WNAME

How to Check Whether the Given Directory/ Path Exists or Not

In Sage X3, we may come across a situation where we need to know whether the path or a particular directory exists or not. We can know this using following function: Syntax: filinfo(path_fil, arg_ent) Parameters: path_fil : Char type expression for the file path to be tested Arg_ent : Integer expression specifying the property to be found. It can be from 0 to 10. Kindly refer to the below snippet of code for better understanding. Here, we have used “7” as  arg_ent  (parameter) of filinfo function which gives size of file in octets. If the file size found is negative, the file does not exist. Here, the path defined in variable  PATH  is valid. Hence the output will be as follows:

3 ways to send a mail from code in Sage X3, with more attachments too

Origen Fuente:  https://en.sagedev.it/sagex3/send-mail-from-code-with-attachments-sage-x3/ Autor:  https://en.sagedev.it/category/sagex3/ In this post I’ll show you how to send a mail from adonix code in Sage X3. The points we will face are: 1) Meladx/Send introduction 2) Sending  through  meladx (the best way for me: at the end with just a single code line you send a mail!) 3) Sending  through  Workflow 4) Sending  through  ENVOI_MAIL(…) From AWRKMEL Sending mail from code in Sage X3: Send vs meladx Sage X3 has two native ways for sending mails. The first way is  meladx  executable file, that you can find in  runtime\bin  directory. The seconde one is Send instruction, that was used to send mail through an application of the client station (for more information on “Send GSERMES”  go here ). The Meladx executable Meladx send messages through SMTP/POP3 protocols by means of the mail  server  specified in the command. When sending is launched by a work

How to Call Function from Different File’s Using Single Call Statement and Encapsulation

While working around the complex functionality, it’s very obvious that you may have to deal with the Multiple source files. Multiple file may define the function with same name but with different set of instruction on the same event or the action and you may want call same function from particular file based on some condition on run time and also want to encapsulate the file name. Code which helps you for Calling Function from Different File’s Using Single Call Statement and Encapsulation. The above code will invoke the TEST sub program from the SPETST2 file, if you have noticed that the different file name is getting encapsulated in the variable ZFILENAME based on certain condition and single statement is enough to call a function from a particular file.

How to Pass Parameter Values to Action through Function in Sage X3

MAY 5, 2017   PUBLISHED BY  PANNI https://www.pannimanagement.com/?blog=how-to-pass-parameter-values-to-action-through-function-in-sage-enterprise-management Passing the parameter values is an important process in Sage X3 V9, especially when we use action parameters through function. The following are the steps to pass values to the action process through function in Sage X3. Create one window for the testing purpose called “YTEST”. Go to All Development Script Dictionary Script Dictionary Actions Action parameters Click the action parameters as shown below. The following screen will appear as shown below Here you can create the new action, which is window entry type and map window, also add a specific process. Add the parameter, which we have created earlier in the action parameters function. Once an action has created successfully with parameters, the next step is to provide the action code to function. These parameters will come up in the parameter field automatically based on the a

Get Action and Function Code in Sage Enterprise Management V9

Sometimes, the developer may require finding the action and function code in coding part. Following example shows how this done in Sage Enterprise Management. In this example, three buttons are added in purchase order window (OPOH) and mapped with three different processes using same process code. All  ->  Development ->  Script Directory Add same process code “SPEYACTION” for three actions “YACTION1”, “YACTION2” and “YFUNCCODE”. All ->  Development ->  Script Directory ->  Actions Write these codes in specific process. Once we have added buttons and actions successfully, then we will have to validate purchase order entry transactions. Button has added in purchase order window successfully as shown. To check go to Orders in Sage Enterprise Management: All ->  Purchasing ->  Orders   Now when we click on button then it should give us action code and function code as shown below. Button Action Code-1   should give “YACTION1” Button Action Code

Valores ACTION

" Acceso Ventana" AVANT_OUVRE DEFTRANS VARIANTE SETTRANS OUVRE BOITE TITRE OUVRE_BOITE DEBUT AFFMASK FILTRE DROIT CLE_GAUCHE VERROU LIENS STYLE SETBOUT "Creación" RAZCRE RAZDUP VERIF_CRE INICRE CREATION APRES_CRE AB_CREATION "Modificación" AVANT_MOD VERIF_MOD AVANT_MODFIC INIMOD MODIF APRES_MOD AB_MODIF "Borrado" AV_VERF_ANU AP_VERF_ANU VERF_ANU AV_ANNULE ANNULE AP_ANNULE "Tableaux" DEFLIG INICRE_LIG INIMOD_LIG LIENS_LIG VALLIG "Browser" TIROIR FILGAUCHE HINT CLE_GAUCHE AP_FILGAUCHE DEB_PICK PICKE DEPICK FIN_PICK "Otros" AV_IMPRIME AP_IMPRIME AV_LISTE AP_LISTE ABANDON AP_MODIF (después de modificar de cada campo) AVANT_ACT  AVANTBOUT EXEBOUT ICONE STATUT