Mirage Source
Compile Error... - Printable Version

+- Mirage Source (https://mirage-engine.uk/forums)
+-- Forum: Mirage Source (Nostalgia) (https://mirage-engine.uk/forums/forumdisplay.php?fid=61)
+--- Forum: Archive (2006-2011) (https://mirage-engine.uk/forums/forumdisplay.php?fid=18)
+---- Forum: General (https://mirage-engine.uk/forums/forumdisplay.php?fid=17)
+---- Thread: Compile Error... (/showthread.php?tid=2133)



Compile Error... - Nean - 19-09-2008

I had to reprogram everything, in the new MS4, because I lost it all (Yay), but now in my new and improved Admin panel, when I try to push the ban button, to send a ban, to the char in the txtbox, it says that theres a compile error, method or data member not found. Heres what I have for the button:

Code:
Private Sub btnban_Click()
    If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
       Call SendBan(Trim(txtchar.Text))
    End If
End Sub

Yes, the textbox is named txchar. However, when I double click the txtbox, it has this:

Code:
Private Sub txtchar_Change(Index As Integer)

End Sub

Sorry to pester you all about such trivial shit, but I'd really like a fix. I tried myself, but to no avail.


Re: Compile Error... - GIAKEN - 19-09-2008

Alright in the properties of the txtchat make sure that the index is blank.


Re: Compile Error... - Mattyw - 19-09-2008

Well mine is:

Code:
Private Sub btnBan_Click()
    If GetPlayerAccess(MyIndex) >= ADMIN_CREATOR Then
        Call SendBan(Trim$(txtPlayer.Text))
    End If
End Sub

Only code difference(apart from access) I see is the $. Try adding that? No idea. :S


Re: Compile Error... - Nean - 19-09-2008

@Giaken: Index is at 0
@Matt: Didn't work.

Could it be that I have a control array setup?


Re: Compile Error... - GIAKEN - 19-09-2008

It needs to be blank.


Re: Compile Error... - Nean - 19-09-2008

GIAKEN Wrote:It needs to be blank.

I can't.
Code:
Can't clear index property, without changing name

FIXED. I did it. Just had to get rid of control array.


Re: Compile Error... - GIAKEN - 19-09-2008

Click the text box, go into the properties box, and look down for Index and to the right of that you'll see "0" or whatever. Just back space that.

Also you'll need to change the name because of conflicts with the other text box.


Re: Compile Error... - Nean - 19-09-2008

GIAKEN Wrote:Click the text box, go into the properties box, and look down for Index and to the right of that you'll see "0" or whatever. Just back space that.

Also you'll need to change the name because of conflicts with the other text box.

Yeah, I couldn't backspace because i guess I had a control array. I had a bunch of textboxes, with the same name. T_T;


Re: Compile Error... - GIAKEN - 19-09-2008

Yeah...whenever it asks you if you want to make a control array just say no.


Re: Compile Error... - Nean - 19-09-2008

GIAKEN Wrote:Yeah...whenever it asks you if you want to make a control array just say no.

Yeah... I usually do... I just wanted to see what it'd do.


Re: Compile Error... - Jacob - 20-09-2008

Do you have a sub call SendBan?


Re: Compile Error... - Nean - 20-09-2008

Dugor Wrote:Do you have a sub call SendBan?

Yeah, I had everything. It was just some stupid control array problem I had. It's fixed now though. =)