M
Mustafa Rabie
hi all,
does anyone has a sample application the uses the opennetcf.phone.callog
class?
i wrote a function that returns reads the calllog and returns a list of the
CallLogEntry(s) that has missed call types, here's the function's code:
private OpenNETCF.Phone.CallLogEntry[] GetAllMissed()
{
OpenNETCF.Phone.CallLog cCallLog = new CallLog();
OpenNETCF.Phone.CallLogEntry[] aRet;
try
{
int n = cCallLog.Seek(OpenNETCF.Phone.CallLogSeek.End,0);
for (int i=0; i < n; i++)
{
if (cCallLog.CallType == OpenNETCF.Phone.CallType.Missed)
{
aRet = cCallLog;
}
}
}
catch (Exception err)
{
string s = err.Message;
}
return aRet;
}
I know that i have to initialize the array b4 using it, but i donno how
since there's no constructor for CallLogEntry class i.e. i can't do the
following
OpenNETCF.Phone.CallLogEntry myEntry = new CallLogEntry();
so how can i initialize the array? since i want to have a dynamic array that
has a length of the number of entried returned,
i do the following with string arrays n it works fine but it doesn't work
with this
string[] myStringList = myString.Split('\\'); // this works gr8
Your help is really appreciated
thanks
mustafa rabie
does anyone has a sample application the uses the opennetcf.phone.callog
class?
i wrote a function that returns reads the calllog and returns a list of the
CallLogEntry(s) that has missed call types, here's the function's code:
private OpenNETCF.Phone.CallLogEntry[] GetAllMissed()
{
OpenNETCF.Phone.CallLog cCallLog = new CallLog();
OpenNETCF.Phone.CallLogEntry[] aRet;
try
{
int n = cCallLog.Seek(OpenNETCF.Phone.CallLogSeek.End,0);
for (int i=0; i < n; i++)
{
if (cCallLog.CallType == OpenNETCF.Phone.CallType.Missed)
{
aRet = cCallLog;
}
}
}
catch (Exception err)
{
string s = err.Message;
}
return aRet;
}
I know that i have to initialize the array b4 using it, but i donno how
since there's no constructor for CallLogEntry class i.e. i can't do the
following
OpenNETCF.Phone.CallLogEntry myEntry = new CallLogEntry();
so how can i initialize the array? since i want to have a dynamic array that
has a length of the number of entried returned,
i do the following with string arrays n it works fine but it doesn't work
with this
string[] myStringList = myString.Split('\\'); // this works gr8
Your help is really appreciated
thanks
mustafa rabie