Results 1 to 26 of 26

Thread: VS 2010 Huge issue ! Please Help !

Threaded View

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Nov 2014
    Posts
    73

    Question VS 2010 Huge issue ! Please Help !

    -------------------------------------------------SOLVED-----------------------------------------------------------------------------------------------



    Note : I am a bit of a novice at coding


    So Im making A Chat Bot Application And Now I Want The Conversation To Be Able To Go In 2 Different Directions. But If I Have 2 Responses That Are The Same For Both Directions At The Same Time , "Yes" and "Yes" For Example, It Uses The Answer To The First Yes Every Time. If I Was Using The Second Side Of The Conversation , This Wouldn't Work , Any Ideas ?


    Okay , Here Is Some Code


    convo2 = Console.ReadLine()
    If convo2 = "Good" Then
    Console.WriteLine("That's Good, Do You Like Cake ?")
    ElseIf convo2 = "Ok" Then
    Console.WriteLine("Anything Bothering You At All ? Maybe A Little Cake Will Cheer You Up, Do You Like Cake ?")
    ElseIf convo2 = "Sad" Then
    Console.WriteLine(" Oh No ! Maybe Cake Will Cheer You Up , Do You Like Cake ?")
    ElseIf convo2 = "Bad" Then
    Console.WriteLine("Oh , Im Sorry To Hear That , Would Pie Cheer You Up ?") 'Line 2 States The 2nd Way The Conversation Could Expand'

    Else
    Console.ForegroundColor = ConsoleColor.Red
    Console.WriteLine("My Systems Can't Find A Response To That , Im Sorry")
    End If
    Console.ReadLine()
    If convo3 = "Yes i love cake" Then
    Console.ForegroundColor = ConsoleColor.Yellow
    Console.WriteLine("Me Too !")
    Console.WriteLine("Did You Know That Thanksgiving Is Coming Up Soon ?")
    ElseIf convo3 = "Yes" Then
    Console.ForegroundColor = ConsoleColor.Yellow
    Console.WriteLine(" Me Too !")
    Console.WriteLine("Did You Know That Thanksgiving Is Coming Up Soon ?")
    ElseIf convo3 = "No" Then
    Console.WriteLine("Oh , We'll I Do ")
    Console.WriteLine("Did You Know That Thanksgiving Is Coming Up Soon ?")
    ElseIf convo3 = "Yes" Then
    Console.WriteLine("Im Glad , I Don't Have Any , But What I Do Have Is A Piece Of String , Would That Be Useful At All ?") 'Line 2'
    Else
    Console.ForegroundColor = ConsoleColor.Red
    Console.WriteLine("My Systems Can't Find A Response To That , Im Sorry")

    End If


    The two yes's in convo3 leads it to say the respons from the first path of the conversation instead of the second path. How do I fix this ?
    Last edited by Jasonpaul2001; Nov 23rd, 2014 at 08:21 PM. Reason: (SOLVED)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width