|
ChannelResourceDropTime Property |
A time at which the server should automatically drop the call whether it is disonnected or not. This value is Universal Time.
Namespace:
VoiceElements.Client
Assembly:
VoiceElementsClient (in VoiceElementsClient.dll) Version: 8.6.1.1
Syntax public DateTime DropTime { get; set; }
Public Property DropTime As DateTime
Get
Set
public:
property DateTime DropTime {
DateTime get ();
void set (DateTime value);
}
member DropTime : DateTime with get, set
Property Value
Type:
DateTimeRemarks
The server will drop the current call at the specified time in
Universal Time. This property has two typical uses, but of course may be used for your applications specific needs:
Safety Net to Avoid Long Calls and Charges
This can be is used as a safety net to ensure that calls do not end up connected for long periods of time. You can take a setting for maximum call length and calucluate the drop time from the time of the call and set it to ensure all calls stay within
a prescibed duration.
End Calls Based on Usage Purchased
Some applications have a caller who has purchased time and the call must be dropped when the customer's purchased time expires. This property works to solve this as well.
Examples
The example below shows a chunk of code that sets the drop time to 8AM univeral time, dials a call and then switches based on the
Dial Result.
public void DialOut()
{
TelephonyServer m_TelephonyServer = new TelephonyServer();
ChannelResource m_ChannelResource = m_TelephonyServer.GetChannel();
string m_PhoneNumber = "2135551212";
m_ChannelResource.DropTime = Convert.ToDateTime("08:00:00");
DialResult dialResult = m_ChannelResource.Dial(m_PhoneNumber);
switch (dialResult)
{
case DialResult.Connected:
break;
case DialResult.NoAnswer:
break;
case DialResult.Busy:
break;
default:
break;
}
}
Public Sub DialOut()
Dim m_TelephonyServer As New TelephonyServer()
Dim m_ChannelResource As ChannelResource = m_TelephonyServer.GetChannel()
Dim m_PhoneNumber As String = "2135551212"
m_ChannelResource.DropTime = Convert.ToDateTime("08:00:00")
Dim dialResult__1 As DialResult = m_ChannelResource.Dial(m_PhoneNumber)
Select Case dialResult__1
Case DialResult.Connected
Exit Select
Case DialResult.NoAnswer
Exit Select
Case DialResult.Busy
Exit Select
Case Else
Exit Select
End Select
End Sub
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.
See Also