fvlmasl2
Active Member
I have a snippet of code that I have been having issues with, on the call to the IB590100_GetDiscount I seem to get issues related to the copying of data needed for the function. The "jdeStrcpy" in the "Main Processing" is where it begins with a "type cast error". What am I doing wrong?
Thanks for ANY assistance.......
HEADER SPEC H
/*****************************************************************************
* Structure Definitions
****************************************************************************/
typedef struct tagDS590100F009
{
MATH_NUMERIC Tier1Qty;
MATH_NUMERIC Tier2Qty;
MATH_NUMERIC Tier3Qty;
MATH_NUMERIC Tier4Qty;
MATH_NUMERIC Tier5Qty;
MATH_NUMERIC Tier1Disc;
MATH_NUMERIC Tier2Disc;
MATH_NUMERIC Tier3Disc;
MATH_NUMERIC Tier4Disc;
MATH_NUMERIC Tier5Disc;
JCHAR TierYN;
} DS590100F009, FAR * LPDS590100F009;
/*****************************************************************************
* Internal Function Prototypes
****************************************************************************/
static ID IB590100_GetDiscount(LPBHVRCOM lpBhvrCom,
LPVOID lpVoid,
LPDS590100F009 lpdsF009);
#endif /* __B590100_H */
======================================================================================================================================================
DETAIL SPEC C
/************************************************************************
* Declare structures
************************************************************************/
DS590100F009 dsF009;
/************************************************************************
* Main Processing
************************************************************************/
jdeStrcpy((JCHAR*)dsF009.TierYN,(const JCHAR*)dsColF5942009.piev01); /* NEED TO COPY THIS TO INTERNAL FUNCTION KEEP GETTING "***** TYPE CAST ERROR ******/
idReturnCode_A = IB590100_GetDiscount(lpBhvrCom, lpVoid,
&dsF009);
/* Internal function comment block */
/**************************************************************************
* Function: Ixxxxxxx_a // Replace "xxxxxxx" with source file number
* // and "a" with the function name
* Notes: NOT BEING USED - FVL
*
* Returns:
*
* Parameters:
**************************************************************************/
static ID IB590100_GetDiscount(LPBHVRCOM lpBhvrCom,
LPVOID lpVoid,
LPDS590100F009 lpdsF009)
{
ID idReturnCode = ER_SUCCESS;
if (lpdsF009->TierYN != _J('Y'))
{
}
return idReturnCode;
}
Thanks for ANY assistance.......
HEADER SPEC H
/*****************************************************************************
* Structure Definitions
****************************************************************************/
typedef struct tagDS590100F009
{
MATH_NUMERIC Tier1Qty;
MATH_NUMERIC Tier2Qty;
MATH_NUMERIC Tier3Qty;
MATH_NUMERIC Tier4Qty;
MATH_NUMERIC Tier5Qty;
MATH_NUMERIC Tier1Disc;
MATH_NUMERIC Tier2Disc;
MATH_NUMERIC Tier3Disc;
MATH_NUMERIC Tier4Disc;
MATH_NUMERIC Tier5Disc;
JCHAR TierYN;
} DS590100F009, FAR * LPDS590100F009;
/*****************************************************************************
* Internal Function Prototypes
****************************************************************************/
static ID IB590100_GetDiscount(LPBHVRCOM lpBhvrCom,
LPVOID lpVoid,
LPDS590100F009 lpdsF009);
#endif /* __B590100_H */
======================================================================================================================================================
DETAIL SPEC C
/************************************************************************
* Declare structures
************************************************************************/
DS590100F009 dsF009;
/************************************************************************
* Main Processing
************************************************************************/
jdeStrcpy((JCHAR*)dsF009.TierYN,(const JCHAR*)dsColF5942009.piev01); /* NEED TO COPY THIS TO INTERNAL FUNCTION KEEP GETTING "***** TYPE CAST ERROR ******/
idReturnCode_A = IB590100_GetDiscount(lpBhvrCom, lpVoid,
&dsF009);
/* Internal function comment block */
/**************************************************************************
* Function: Ixxxxxxx_a // Replace "xxxxxxx" with source file number
* // and "a" with the function name
* Notes: NOT BEING USED - FVL
*
* Returns:
*
* Parameters:
**************************************************************************/
static ID IB590100_GetDiscount(LPBHVRCOM lpBhvrCom,
LPVOID lpVoid,
LPDS590100F009 lpdsF009)
{
ID idReturnCode = ER_SUCCESS;
if (lpdsF009->TierYN != _J('Y'))
{
}
return idReturnCode;
}