Skip to content
Permalink
Browse files
Updated a bug that caused an exception to be thrown when moving a sli…
…de to the first position, VB code needs to be checked as I am not as familiar with VB
  • Loading branch information
Russel Rillema committed May 30, 2019
1 parent 4da9c98 commit 9697e09a3021a86d974ee0ff182c6657abe17433
Showing with 4 additions and 7 deletions.
  1. +4 −7 docs/how-to-move-a-slide-to-a-new-position-in-a-presentation.md
@@ -348,7 +348,7 @@ source slide) is identified.
{
targetSlide = null;
}
if (from < to)
else if (from < to)
{
targetSlide = slideIdList.ChildElements[to] as SlideId;
}
@@ -374,8 +374,7 @@ source slide) is identified.
' Identify the position of the target slide after which to move the source slide.
If to = 0 Then
targetSlide = Nothing
End If
If From < to Then
ElseIf From < to Then
targetSlide = TryCast(slideIdList.ChildElements(to), SlideId)
Else
targetSlide = TryCast(slideIdList.ChildElements(to - 1), SlideId)
@@ -514,7 +513,7 @@ Following is the complete sample code in both C\# and Visual Basic.
{
targetSlide = null;
}
if (from < to)
else if (from < to)
{
targetSlide = slideIdList.ChildElements[to] as SlideId;
}
@@ -616,9 +615,7 @@ Following is the complete sample code in both C\# and Visual Basic.
' Identify the position of the target slide after which to move the source slide.
If (moveTo = 0) Then
targetSlide = Nothing
End If
If (from < moveTo) Then
ElseIf (from < moveTo) Then
targetSlide = CType(slideIdList.ChildElements(moveTo), SlideId)
Else
targetSlide = CType(slideIdList.ChildElements((moveTo - 1)), SlideId)

0 comments on commit 9697e09

Please sign in to comment.