axis-c-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Prem <>
Subject Axis2C - getting junk character in response after setting the values in S ET method
Date Tue, 03 Apr 2007 06:39:19 GMT


we are using the following srtuct in webservice creation.

struct  item
   int   id;
   char*  strvalue1;
   char*  strvalue2;

1. we are using a COM API  function which returns _variant_t variable

2. Converting it into char* and trying to set the struct variable using the
set method of AXIS2C 
   but it responses with junk values for the above sructure
   the following code explains ..
   struct item*  itemdtls;
   struct axis2_item* getitem_out = NULL;

	axis2_GetDefectItemResponse_t* getitem_response = NULL;
   		axis2_GetItemResponse_t*  getitem_response = NULL;
   		int intput_val = 0;
   		intput_val = AXIS2_GETDEFECTITEM_GET_ID(getItem, env);
   		itemdtls = GetDefectItem(14);  // calling COM API
   		                               // it returns all tyhe (char*)values
from the DB
   	    	getitem_out = axis2_Item_create(env);
   		AXIS2_ITEM_SET_ID(getitem_out, env, itemdtls->id);        // setting
the com api returned values
		AXIS2_ITEM_SET_STRVALUE1(getitem_out, env, itemdtls->strvalue1);
		AXIS2_ITEM_SET_STRVALUE1(getitem_out, env, itemdtls->strvalue2)
		getitem_response = axis2_GetItemResponse_create(env);

		AXIS2_GETITEMRESPONSE_SET_ITEMRETURN(getitem_response, env, getitem_out);
		return getitem_response;
   it compiles and deployed the dll in service folder of Axis2c setup.		
3.   using  java client to invoke the service but it responses with junk
characters for the above struct variable.

IMP: while debugging the COM API, it  returns value.   

can any one help to solve the above to  set the value in response object.


View this message in context:
Sent from the Axis - C++ - User mailing list archive at

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message