Skip to content

Commit 5134c28

Browse files
committed
Windows changes
1 parent d41f647 commit 5134c28

File tree

1 file changed

+29
-2
lines changed

1 file changed

+29
-2
lines changed

articles/communication-services/quickstarts/voice-video-calling/includes/teams-interop/teams-interop-windows.md

Lines changed: 29 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ In this quickstart, you'll learn how to join a Teams meeting using the Azure Com
1414

1515
- A working [Communication Services calling Windows app](../../getting-started-with-calling.md).
1616
- A [Teams deployment](/deployoffice/teams-install).
17+
- The Minimum Version supported for Teams meetingId and passcode join API : 1.7.0
1718
- An [access token](../../../identity/access-tokens.md).
1819

1920
## Add the Teams UI controls and Enable the Teams UI controls
@@ -39,14 +40,20 @@ Replace code in MainPage.xaml with following snippet. The text box will be used
3940
<RowDefinition Height="60*"/>
4041
<RowDefinition Height="16*"/>
4142
</Grid.RowDefinitions>
42-
<TextBox Grid.Row="1" x:Name="CalleeTextBox" PlaceholderText="Who would you like to call?" TextWrapping="Wrap" VerticalAlignment="Center" Height="30" Margin="10,10,10,10" />
4343

44-
<Grid x:Name="AppTitleBar" Background="LightSeaGreen">
44+
<Grid Grid.Row="0" x:Name="AppTitleBar" Background="LightSeaGreen">
4545
<!-- Width of the padding columns is set in LayoutMetricsChanged handler. -->
4646
<!-- Using padding columns instead of Margin ensures that the background paints the area under the caption control buttons (for transparent buttons). -->
4747
<TextBlock x:Name="QuickstartTitle" Text="Calling Quickstart sample title bar" Style="{StaticResource CaptionTextBlockStyle}" Padding="7,7,0,0"/>
4848
</Grid>
4949

50+
<StackPanel Grid.Row="1">
51+
<TextBox x:Name="CalleeTextBox" PlaceholderText="Who would you like to call?" TextWrapping="Wrap" VerticalAlignment="Center" />
52+
<TextBlock Text="or" Padding="7,7,0,0" />
53+
<TextBox x:Name="CalleeMeetingId" PlaceholderText="Teams Meeting Id" TextWrapping="Wrap" VerticalAlignment="Center" />
54+
<TextBox x:Name="CalleeMeetingPasscode" PlaceholderText="Teams Meeting Passcode" TextWrapping="Wrap" VerticalAlignment="Center" />
55+
</StackPanel>
56+
5057
<Grid Grid.Row="2">
5158
<Grid.RowDefinitions>
5259
<RowDefinition/>
@@ -121,11 +128,17 @@ namespace CallingQuickstart
121128
private async void CallButton_Click(object sender, RoutedEventArgs e)
122129
{
123130
var callString = CalleeTextBox.Text.Trim();
131+
var meetingId = CalleeMeetingId.Text.Trim();
132+
var passcode = CalleeMeetingPasscode.Text.Trim();
124133

125134
if (!string.IsNullOrEmpty(callString))
126135
{
127136
call = await JoinTeamsMeetingByLinkAsync(teamsMeetinglink);
128137
}
138+
else if (!string.IsNullOrEmpty(meetingId) && !string.IsNullOrEmpty(passcode))
139+
{
140+
call = await JoinTeamsMeetingByMeetingIdAsync(meetingId, passcode);
141+
}
129142

130143
if (call != null)
131144
{
@@ -333,6 +346,15 @@ namespace CallingQuickstart
333346
return call;
334347
}
335348

349+
private async Task<CommunicationCall> JoinTeamsMeetingByMeetingIdAsync(String meetingId, String passcode)
350+
{
351+
var joinCallOptions = GetJoinCallOptions();
352+
353+
var teamsMeetingIdLocator = new TeamsMeetingIdLocator(meetingId, passcode);
354+
var call = await callAgent.JoinAsync(teamsMeetingIdLocator, joinCallOptions);
355+
return call;
356+
}
357+
336358
private JoinCallOptions GetJoinCallOptions()
337359
{
338360
return new JoinCallOptions() {
@@ -351,6 +373,11 @@ namespace CallingQuickstart
351373
The Teams meeting link can be retrieved using Graph APIs. This is detailed in [Graph documentation](/graph/api/onlinemeeting-createorget?tabs=http&view=graph-rest-beta&preserve-view=true).
352374
The Communication Services Calling SDK accepts a full Teams meeting link. This link is returned as part of the `onlineMeeting` resource, accessible under the [`joinWebUrl` property](/graph/api/resources/onlinemeeting?view=graph-rest-beta&preserve-view=true). You can also get the required meeting information from the **Join Meeting** URL in the Teams meeting invite itself.
353375

376+
## Get the Teams meeting ID and passcode
377+
* Graph API: Use Graph API to retrieve information about onlineMeeting resource and check the object in property joinMeetingIdSettings.
378+
* Teams: In your Teams application, go to Calendar app and open details of a meeting. Online meetings have meeting ID and passcode in the definition of the meeting.
379+
* Outlook: You can find the meeting ID & passcode in calendar events or in email meeting invites.
380+
354381
## Launch the app and join Teams meeting
355382

356383
You can build and run your app on Visual Studio by selecting **Debug** > **Start Debugging** or by using the (F5) keyboard shortcut.

0 commit comments

Comments
 (0)