如何使用户出错的抽认卡更频繁地出现 - visual basic
how to make flashcards that the user gets wrong appear more often - visual basic
我正在创建一个显示用户创建的抽认卡的抽认卡应用程序
Private Sub btnDisplay_Click(sender As Object, e As EventArgs) Handles btnDisplay.Click
btnDisplay.Enabled = False
Dim index = rand.Next(dt.Rows.Count) ' generates index in the range 0 .. Count - 1
txtFront.Text = dt.Rows(index)(2).ToString()
txtBack.Visible = False
txtBack.Text = dt.Rows(index)(3).ToString()
End Sub
Private Sub btnEasy_Click(sender As Object, e As EventArgs) Handles btnEasy.Click
Dim index = rand.Next(dt.Rows.Count) ' generates index in the range 0 .. Count - 1
If txtBack.Visible = True Then
txtFront.Text = dt.Rows(index)(2).ToString()
txtBack.Visible = False
txtBack.Text = dt.Rows(index)(3).ToString()
Else
MsgBox("Please first reveal the back of the flashcard")
End If
End Sub
Private Sub btnGood_Click(sender As Object, e As EventArgs) Handles btnGood.Click
Dim index = rand.Next(dt.Rows.Count) ' generates index in the range 0 .. Count - 1
If txtBack.Visible = True Then
txtFront.Text = dt.Rows(index)(2).ToString()
txtBack.Visible = False
txtBack.Text = dt.Rows(index)(3).ToString()
Else
MsgBox("Please first reveal the back of the flashcard")
End If
End Sub
Private Sub btnHard_Click(sender As Object, e As EventArgs) Handles btnHard.Click
Dim index = rand.Next(dt.Rows.Count) ' generates index in the range 0 .. Count - 1
If txtBack.Visible = True Then
txtFront.Text = dt.Rows(index)(2).ToString()
txtBack.Visible = False
txtBack.Text = dt.Rows(index)(3).ToString()
Else
MsgBox("Please first reveal the back of the flashcard")
End If
End Sub
Private Sub btnReveal_Click(sender As Object, e As EventArgs) Handles btnReveal.Click
txtBack.Visible = True
End Sub
当前代码显示存储在访问数据库中的随机抽认卡。我想知道是否有一种方法可以更频繁地出现用户错误的抽认卡(有点像 anki)。
因此,如果用户单击 btnEasy 按钮,抽认卡不太可能再次出现,如果用户按下 btnHard 按钮,则抽认卡出现的可能性更大。
对于每张卡片,您可以跟踪一些 GoodUntil
DateTime variable which represents the time at which it should be shown again, like Anki does. When cards are first created, you set that value to Now,以便卡片可以立即展示给学生。然后,每次学生看到卡片时,您都会根据学生点击的内容(简单、良好、困难等)将 GoodUntil
更新为新日期。例如,如果用户点击:
- 简单:将
GoodUntil
设置为从现在起 10 天
- 好:将
GoodUntil
设置为从现在起 2 天
- 困难:将
GoodUntil
设置为从现在开始 5 分钟。
寻找下一张要显示的牌时,查看每张牌的 GoodUntil
值并使用 Now compare 值。如果小于 0,则准备再次显示。
这是执行此操作的基本方法,但应该运行良好。您还应该跟踪每张卡片的分数,该分数将跟踪学生使用卡片的情况。如果学生点击卡片上的 Easy,你想记录下一次,如果他再次点击 Easy,你可以将 GoodUntil
日期设置为 30 天,如果他再次点击 Easy 则为 60 天,等等.
当找不到更多的卡片时,您可以向学生显示一些消息,告诉他们他们已完成学习。
我正在创建一个显示用户创建的抽认卡的抽认卡应用程序
Private Sub btnDisplay_Click(sender As Object, e As EventArgs) Handles btnDisplay.Click
btnDisplay.Enabled = False
Dim index = rand.Next(dt.Rows.Count) ' generates index in the range 0 .. Count - 1
txtFront.Text = dt.Rows(index)(2).ToString()
txtBack.Visible = False
txtBack.Text = dt.Rows(index)(3).ToString()
End Sub
Private Sub btnEasy_Click(sender As Object, e As EventArgs) Handles btnEasy.Click
Dim index = rand.Next(dt.Rows.Count) ' generates index in the range 0 .. Count - 1
If txtBack.Visible = True Then
txtFront.Text = dt.Rows(index)(2).ToString()
txtBack.Visible = False
txtBack.Text = dt.Rows(index)(3).ToString()
Else
MsgBox("Please first reveal the back of the flashcard")
End If
End Sub
Private Sub btnGood_Click(sender As Object, e As EventArgs) Handles btnGood.Click
Dim index = rand.Next(dt.Rows.Count) ' generates index in the range 0 .. Count - 1
If txtBack.Visible = True Then
txtFront.Text = dt.Rows(index)(2).ToString()
txtBack.Visible = False
txtBack.Text = dt.Rows(index)(3).ToString()
Else
MsgBox("Please first reveal the back of the flashcard")
End If
End Sub
Private Sub btnHard_Click(sender As Object, e As EventArgs) Handles btnHard.Click
Dim index = rand.Next(dt.Rows.Count) ' generates index in the range 0 .. Count - 1
If txtBack.Visible = True Then
txtFront.Text = dt.Rows(index)(2).ToString()
txtBack.Visible = False
txtBack.Text = dt.Rows(index)(3).ToString()
Else
MsgBox("Please first reveal the back of the flashcard")
End If
End Sub
Private Sub btnReveal_Click(sender As Object, e As EventArgs) Handles btnReveal.Click
txtBack.Visible = True
End Sub
当前代码显示存储在访问数据库中的随机抽认卡。我想知道是否有一种方法可以更频繁地出现用户错误的抽认卡(有点像 anki)。 因此,如果用户单击 btnEasy 按钮,抽认卡不太可能再次出现,如果用户按下 btnHard 按钮,则抽认卡出现的可能性更大。
对于每张卡片,您可以跟踪一些 GoodUntil
DateTime variable which represents the time at which it should be shown again, like Anki does. When cards are first created, you set that value to Now,以便卡片可以立即展示给学生。然后,每次学生看到卡片时,您都会根据学生点击的内容(简单、良好、困难等)将 GoodUntil
更新为新日期。例如,如果用户点击:
- 简单:将
GoodUntil
设置为从现在起 10 天 - 好:将
GoodUntil
设置为从现在起 2 天 - 困难:将
GoodUntil
设置为从现在开始 5 分钟。
寻找下一张要显示的牌时,查看每张牌的 GoodUntil
值并使用 Now compare 值。如果小于 0,则准备再次显示。
这是执行此操作的基本方法,但应该运行良好。您还应该跟踪每张卡片的分数,该分数将跟踪学生使用卡片的情况。如果学生点击卡片上的 Easy,你想记录下一次,如果他再次点击 Easy,你可以将 GoodUntil
日期设置为 30 天,如果他再次点击 Easy 则为 60 天,等等.
当找不到更多的卡片时,您可以向学生显示一些消息,告诉他们他们已完成学习。