Daneta Posted May 20, 2013 Author Share Posted May 20, 2013 ```Sub SendData(ByRef data() As Byte)Dim Buffer As clsBuffer' If debug mode, handle error then exit outIf Options.Debug = 1 Then On Error GoTo errorhandlerIf IsConnected Then Set Buffer = New clsBuffer Buffer.WriteLong (UBound(data) - LBound(data)) + 1 Buffer.WriteBytes data() frmMain.Socket.SendData Buffer.ToArray()End If' Error handlerExit Suberrorhandler:HandleError "SendData", "modClientTCP", Err.Number, Err.Description, Err.Source, Err.HelpContextErr.ClearExit SubEnd Sub```ok when i complie it i get this error it says method or data members not found to the word .socket Link to comment Share on other sites More sharing options...
Zeno Posted May 20, 2013 Share Posted May 20, 2013 You need a winsock named Socket in your frmMain. Double-check that its name is Socket. It must have 0-TCP as the socket type.Have you changed your frmMain? Link to comment Share on other sites More sharing options...
Daneta Posted May 20, 2013 Author Share Posted May 20, 2013 i went in the file and saw this it said frmmain but it was a notepad file it saidLine 46: Cannot load control Socket; license not found. why Link to comment Share on other sites More sharing options...
Zeno Posted May 20, 2013 Share Posted May 20, 2013 frmmasin? Make sure it's titled frmMain. It probably is - but jeez man, take an extra minute to type properly.In this case, I'm guessing the license is not found because you are using an incomplete version of VB6\. Which version of the VB6 IDE do you have installed? You need either VB6 Enterprise or VB6 Pro. Free, trial, or portable will not cut it. Link to comment Share on other sites More sharing options...
Daneta Posted May 20, 2013 Author Share Posted May 20, 2013 idk what i have Link to comment Share on other sites More sharing options...
Zeno Posted May 21, 2013 Share Posted May 21, 2013 Look at what the loader says when you first run VB6\. There should be a white box with some text.If you're still at a loss, look under help-> about and read after VBA: Link to comment Share on other sites More sharing options...
Daneta Posted May 21, 2013 Author Share Posted May 21, 2013 when i post tjis in modgraphicsPublic Sub DrawHair(ByVal x2 As Long, ByVal y2 As Long, ByVal Hair As Long, ByVal Anim As Long, ByVal spritetop As Long, ByVal tint As Long)Dim rec As RECTIf Hair < 1 Or Hair > NumHairs Then Exit SubWith rec.Top = spritetop * (Tex_Hair(Hair).Height / 4).Bottom = .Top + (Tex_Hair(Hair).Height / 4).Left = Anim * (Tex_Hair(Hair).Width / 4).Right = .Left + (Tex_Hair(Hair).Width / 4)End With' Clip to screenIf y2 < 0 ThenWith rec.Top = .Top - y2End Withy2 = 0End IfIf x2 < 0 ThenWith rec.Left = .Left - x2End Withx2 = 0End If'RenderTexture Tex_Hair(Hair), ConvertMapX(x2), ConvertMapY(y2), rec.Left, rec.Top, rec.Right - rec.Left, rec.Bottom - rec.Top, rec.Width, rec.HeightRenderTexture Tex_Hair(Hair), ConvertMapX(x2), ConvertMapY(y2), rec.Left, rec.Top, rec.Right - rec.Left, rec.Bottom - rec.Top, rec.Right - rec.Left, rec.Bottom - rec.Top, tintEnd Suband i try to compliei get this error ambiguous name detected: draw hairnow i get that Link to comment Share on other sites More sharing options...
Zeno Posted May 21, 2013 Share Posted May 21, 2013 Do not post the same question in multiple threads. You probably have two subs named DrawHair. Link to comment Share on other sites More sharing options...
Daneta Posted May 21, 2013 Author Share Posted May 21, 2013 ok i posted another error i got on the tut thread Link to comment Share on other sites More sharing options...
Zeno Posted May 21, 2013 Share Posted May 21, 2013 Although you got them after following the tutorial, your errors aren't really relevant to the tutorial. I know this because they involve things which the tutorial doesn't even touch. You should post them here.> now i get this> > ```> > ' connect> > frmMain.Socket.RemoteHost = Options.IP> > frmMain.Socket.RemotePort = Options.Port> > ```> > were it says socket.remotehost is were i cet the complie error it says method or data member not found why is it because of the vb6 im usingWhen you go to type frmMain.Socket.Remote into the IDE, does anything pop up?![](http://freemmorpgmaker.com/uploadfiles/a01a02129fc239dc23571f1330fdd526.jpg)If nothing pops up, you are missing a winsock named Socket in frmMain.If you see something like above, there is no error in your code or forms. Rather, you are using an improper version of the VB6.0 IDE and will have to download either the enterprise or professional version. Do not get the trial, free, or portable versions. Go for Visual Studio 6.0, Visual Basic 6.0 Enterprise, or Visual Basic 6.0 Professional. Link to comment Share on other sites More sharing options...
Daneta Posted May 21, 2013 Author Share Posted May 21, 2013 well i will try it later because my vb6 isint loading and should i just get a new vb6```Sub TcpInit() ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler Set PlayerBuffer = New clsBuffer ' connect frmMain.Socket.RemoteHost = Options.IP frmMain.Socket.RemotePort = Options.Port ' Error handler Exit Suberrorhandler: HandleError "TcpInit", "modClientTCP", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd Sub```and theres the full code maby its something in there Link to comment Share on other sites More sharing options...
Zeno Posted May 21, 2013 Share Posted May 21, 2013 The "full code" would involve anything and everything to do with frmMain.Socket. Anyway, doesn't really matter. Think about this: you haven't touched that bit of code and it's been working for hundreds, if not thousands, of other people. So, no, it's not something in there. It's your inadequate VB6 IDE. It won't even load? Get a proper version. Link to comment Share on other sites More sharing options...
abhi2011 Posted May 21, 2013 Share Posted May 21, 2013 I didn't read through the entire topic, so forgive me if this has already been stated.* Install the run times again.* Try to manually register mswinsck.ocx* Go back to frmMain.* Find the socket control.* Delete it.* Add a new one and name it Socket.* Save it and Recompile. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now