i am developing a simple tic tac toe game for Windows mobile using VB all the components are working fine except i am having this error on this line of code

Error: Error 1 Requested operation is not available because the runtime library function 'Microsoft.VisualBasic.CompilerServices.Operators.CompareObjectEqual' is not defined. C:\Users\...\MainPage.xaml.vb 18 12 PhoneApp2

the error location is

If Button1.Content = "X" And Button2.Content = "X" And Button3.Content = "X" Then
            TextBox1.Text = "Player X wins"
        End If

Can someone help me on this

If you use the .Equals() method, does it give the same error?

hey have you check Button1.Content of Button1. what if it contain null value??

I guess it's because you are trying to compare an object to a value

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.