الفريق العربي للبرمجةأرشيف المنتديات · 2000 – 2023
نسخة أرشيفية للقراءة فقط — التسجيل والمشاركة مغلقان، والمحتوى محفوظ كما كان.

إرسال رسالة من الجوال

مغلق
بدأه شبح البرمجة في 7 مايو 2005 · 2 رد · 546 مشاهدة · في لغة Ms Visual Basic 6 وما قبلها من إصدارات
مشاركة: واتساب X فيسبوك تيليجرام
#1 صاحب الموضوع

(h) لوسمحتم يا جماعة ساعدوني هذا كود لإرسال رسالة من الجوال و لكن لا أعرف كيف يعمل:

Dim SMS As Simplewire.SMS 
Dim carrier As Simplewire.SMSCarrier 
Dim Index As Integer 
' instantiate the the request 
Set SMS = New Simplewire.SMS 
' send off a carrier list request 
SMS.CarrierListSend 
' first off, we need to check if the req
'     uest was a success 
If SMS.Success = False Then 
' display the error description 
MsgBox SMS.ErrorDesc & " " & SMS.ErrorCode, vbCritical, "Carrier List Error" 
' kill the pager interfaces 
Set SMS = Nothing 
' stop the program 
End 
' otherwise, we have a valid response 
Else 
' resize PagerService array to make a pe
'     rfect fit 
ReDim SMSCarrierID(SMS.CarrierList.Count) 
ReDim SMSCarrierTextMaxLength(SMS.CarrierList.Count) 
' init the integer 
Index = 0 
' loop until the next service doesnt exi
'     st 


For Each carrier In SMS.CarrierList 
    ' set the new item on the combo box and 
    '     set the subtitle in the 
    .CarrierList.AddItem carrier.Title & " " & carrier.Subtitle 
    ' set the service id for the global serv
    '     ice id array 
    SMSCarrierID(Index) = carrier.ID 
    SMSCarrierTextMaxLength(Index) = carrier.TextMaxLength 
    ' increment the index 
    Index = Index + 1 
Next 
' init the list 
.CarrierList.ListIndex = 0 
End If 
' kill the sms object 
Set SMS = Nothing

وهذا كود لإستقبال المكالمات :

Private Sub Form_Load() 
MSComm1.Settings = "9600,N,8,1" 
' áæÈ ááÊÔííß Úáì ÚÔÑÉ ãäÇÝÐ æÅÓÊÎÑÇÌ ÑÞã ãäÝÐ ÇáãæÏæã ÇáÕÍíÍ 

For i = 1 To 10 
MSComm1.CommPort = i 

On Error GoTo N 
MSComm1.PortOpen = True 

N: 
If MSComm1.PortOpen = True Then 
Exit For 
End If 

Next 

End Sub 

Private Sub MSComm1_OnComm() 

If MSComm1.CommEvent Then 

MsgBox " æÕæá ÅÊÕÇá áß " 

End If 


End Sub

وهذا كود لتفريغ الذاكرة

Dim f As Integer 
f = Forms.Count 
Do While f > 0 
Unload Forms(f - 1) ' 
If form isn't 
unloaded 
exit (User had canceled...)
If f = Forms.Count Then 
Exit Do f = f - 1 
Loop 
End

إذا سمحتم إعطوني شرحا و فيا لكل كود

و شكرا

#2
/index.ph...opic=64527&st=0

الإنسان الذي يقول بأنه لا يمكن عمل شيء يجب ألا يعيق مطلقاً الإنسان الذي يقوم بعمل ذلك الشيء.

إن تخطئ فأنت إنسان ... أما أن تلوم جهازك الكمبيوتر على خطأك فهذا أكثر إنسانية.

#3

شكرا يا أخي ولكن الكود الأول لايعمل والكود الثاني و الثالث فيه أخطاء

الكود الثاني ليت متأكد من عملهم

تم تعديل هذه المشاركة بواسطة شبح البرمجة في 8 مايو 2005 في 23:04

هذا الموضوع مغلق.

مواضيع مشابهة