Download SMS Messaging Server    |     Visit the SMS Messaging Server website

Index - Log in! - Sign up! - Visit website
Wap push error
 
ActiveXperts Software Forum Index -> SMS Messaging Server -> General
 
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
smitha.p



Joined: 01 Mar 2008
Posts: 6

PostPosted: Sat Mar 01, 2008 8:00 am    Post subject: Wap push error

I am trying to wap push from .net using GSMOUT in active experts library. using MO 200 GPRS modem. The sending sms is working.
But it is throwing the following error from wap push module.
'Attempted to read or write protected memory. This is often an indication that other memory is corrupt.' while doing objWap.ConnectionType =objConstants.asWAPPUSH_SERVICE_INDICATION.
Can some one please help. I am attaching the code below.


string[] status = new string[2];
ASmsCtrl.WapPush objWap = new ASmsCtrl.WapPush();
ASmsCtrl.ConstantsClass objConstants = new ASmsCtrl.ConstantsClass();
objWap.ConnectionType = objConstants.asWAPPUSH_SERVICE_INDICATION;
//objWap.ConnectionType = 0;
objWap.URL = url;
objWap.Description = message;
objWap.SignalReference = "6532";
objWap.SignalAction = objConstants.asWAPPUSHSIGNAL_MEDIUM;
int nMessageParts = objWap.Encode();

GsmOut objGsmOut = new GsmOut();
objGsmOut.Device = ConfigurationSettings.AppSettings["gsmDevice"].
ToString();
objGsmOut.MessageType = objConstants.asMESSAGETYPE_DATA_UDH;
//asMESSAGETYPE_DATA_UDH;
objGsmOut.MessageRecipient = mPhoneNo;

for (int i = 0; i < nMessageParts; i++)
{
objGsmOut.MessageData = objWap.GetMessagePart(i);
objGsmOut.Send();

}

if (objGsmOut.LastError == 0)
{
status[0] = "1";
status[1] = objGsmOut.MessageReference.ToString();
}
else
{
status[0] = "0";
status[1] = objGsmOut.GetErrorDescription(objGsmOut.LastError);
}
objGsmOut.Clear();
return status;
Back to top
Leon



Joined: 11 Jul 2007
Posts: 408

PostPosted: Tue Mar 04, 2008 11:41 am    Post subject:

Hi,

Thank you for your post. Can you try the following:

replace

ASmsCtrl.ConstantsClass objConstants = new ASmsCtrl.ConstantsClass();

with

ASmsCtrl.ConstantsClass objConstants = new ASmsCtrl.SmsConstantsClass();

Hope this solves the problem

Leon
Back to top
smitha.p



Joined: 01 Mar 2008
Posts: 6

PostPosted: Thu Mar 06, 2008 10:30 am    Post subject:

There is no such class ASmsCtrl.SmsConstantsClass is the library.
Back to top
Display posts from previous:   
Post new topic   Reply to topic
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum