To keep it simple I created:
/*****************************************************************************
* Header File: B56TEST.h
*
* Description: Test for NID errors Header File
*
* History:
* Date Programmer SAR# - Description
* ---------- ---------- -------------------------------------------
* Author 10/16/09 Unkno Unknown - Created
*
*
* Copyright (c) J.D. Edwards World Source Company, 1996
*
* This unpublished material is proprietary to J.D. Edwards World Source
* Company. All rights reserved. The methods and techniques described
* herein are considered trade secrets and/or confidential. Reproduction
* or distribution, in whole or in part, is forbidden except by express
* written permission of J.D. Edwards World Source Company.
****************************************************************************/
#ifndef __B56TEST_H
#define __B56TEST_H
/*****************************************************************************
* Table Header Inclusions
****************************************************************************/
/*****************************************************************************
* External Business Function Header Inclusions
****************************************************************************/
/*****************************************************************************
* Global Definitions
****************************************************************************/
/*****************************************************************************
* Structure Definitions
****************************************************************************/
/*****************************************
* TYPEDEF for Data Structure
* Template Name: Test for NID errors
* Template ID: D56TEST
* Generated: Fri Oct 16 08:08:51 2009
*
* DO NOT EDIT THE FOLLOWING TYPEDEF
* To make modifications, use the OneWorld Data Structure
* Tool to Generate a revised version, and paste from
* the clipboard.
*
**************************************/
#ifndef DATASTRUCTURE_D56TEST
#define DATASTRUCTURE_D56TEST
typedef struct tagDSD56TEST
{
MATH_NUMERIC mnDocumentOrderInvoiceE;
JCHAR szOrderType[3];
} DSD56TEST, *LPDSD56TEST;
#define IDERRmnDocumentOrderInvoiceE_1 1L
#define IDERRszOrderType_2 2L
#endif
/*****************************************************************************
* DS Template Type Definitions
****************************************************************************/
/*****************************************************************************
* Source Preprocessor Definitions
****************************************************************************/
#if defined (JDEBFRTN)
#undef JDEBFRTN
#endif
#if defined (WIN32)
#if defined (WIN32)
#define JDEBFRTN(r) __declspec(dllexport) r
#else
#define JDEBFRTN(r) __declspec(dllimport) r
#endif
#else
#define JDEBFRTN(r) r
#endif
/*****************************************************************************
* Business Function Prototypes
****************************************************************************/
JDEBFRTN (ID) JDEBFWINAPI TestBSFN (LPBHVRCOM lpBhvrCom, LPVOID lpVoid, LPDSD56TEST lpDS);
/*****************************************************************************
* Internal Function Prototypes
****************************************************************************/
#endif /* __B56TEST_H */
/************************************************/
/************************************************/
/************************************************/
#include <jde.h>
#define b56test_c
/*****************************************************************************
* Source File: b56test
*
* Description: Test for NID errors Source File
*
* History:
* Date Programmer SAR# - Description
* ---------- ---------- -------------------------------------------
* Author 10/16/09 Unkno Unknown - Created
*
* Copyright (c) J.D. Edwards World Source Company, 1996
*
* This unpublished material is proprietary to J.D. Edwards World Source Company.
* All rights reserved. The methods and techniques described herein are
* considered trade secrets and/or confidential. Reproduction or
* distribution, in whole or in part, is forbidden except by express
* written permission of J.D. Edwards World Source Company.
****************************************************************************/
/**************************************************************************
* Notes:
*
**************************************************************************/
#include <b56test.h>
/**************************************************************************
* Business Function: TestBSFN
*
* Description: Test Business Function
*
* Parameters:
* LPBHVRCOM lpBhvrCom Business Function Communications
* LPVOID lpVoid Void Parameter - DO NOT USE!
* LPDSD56T lpDS Parameter Data Structure Pointer
*
*************************************************************************/
JDEBFRTN (ID) JDEBFWINAPI TestBSFN (LPBHVRCOM lpBhvrCom, LPVOID lpVoid, LPDSD56TEST lpDS)
{
/************************************************************************
* Variable declarations
************************************************************************/
/************************************************************************
* Declare structures
************************************************************************/
/************************************************************************
* Declare pointers
************************************************************************/
/************************************************************************
* Check for NULL pointers
************************************************************************/
if ((lpBhvrCom == (LPBHVRCOM) NULL) ||
(lpVoid == (LPVOID) NULL) ||
(lpDS == (LPDSD56TEST) NULL))
{
jdeErrorSet (lpBhvrCom, lpVoid, (ID) 0, _J("4363"), (LPVOID) NULL);
return ER_ERROR;
}
/************************************************************************
* Set pointers
************************************************************************/
/************************************************************************
* Main Processing
************************************************************************/
#define NUMCOLS 2
NID szArray[NUMCOLS] = {NID_DOCO,NID_DCTO};
/************************************************************************
* Function Clean Up
************************************************************************/
return (ER_SUCCESS);
}
/* Internal function comment block */
/**************************************************************************
* Function: Ixxxxxxx_a // Replace "xxxxxxx" with source file number
* // and "a" with the function name
* Notes:
*
* Returns:
*
* Parameters:
**************************************************************************/