Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::GeorgeS's Tools

Development::GeorgeS's Tools A forum just for GeorgeS's tools

Reply
 
Thread Tools Display Modes
  #1  
Old 06-20-2008, 09:13 AM
nosfentora
Discordant
 
Join Date: Oct 2004
Location: In a house
Posts: 387
Default

Hey GeorgeS,

Once you have MySQL Connector.Net 5.1.6 installed,
add a reference to it (MySQL.Data)


Code:
Imports MySql.Data.MySqlClient
Public Class MyClass

    Private mydb As New MySqlConnection()
    Private con_str As String = ""
    Private reader As MySqlDataReader

    Public Sub New()
        con_str = "server=SERVER_IP;Port=3306;user id=root;password=PASSWORD_HERE;database=DATABASE_NAME;persist security info=True"
        mydb.ConnectionString = con_str

        mydb.Open()

        Dim sql_cmd as String = "SELECT * FROM variables"
        Dim cmd As New MySqlCommand(sql_cmd, mydb)

        reader = cmd.ExecuteReader
        While reader.Read
            For i As Integer = 0 To reader.FieldCount - 1
                debug.WriteLine(reader.Item(i).ToString)
            Next
        End While
        reader.Close()
        reader = Nothing
        mydb.Close()
        mydb.Dispose()

    End Sub
End Class

Last edited by Kayot; 06-21-2008 at 04:32 AM.. Reason: Always use code brackets, its the polite way to post code XD
Reply With Quote
  #2  
Old 06-20-2008, 09:28 AM
nosfentora
Discordant
 
Join Date: Oct 2004
Location: In a house
Posts: 387
Default

I have a transactional database interface class that i wrote, that if you're comfortable with array lists, then it'll probably be a big help.
Reply With Quote
  #3  
Old 06-20-2008, 08:42 PM
Kayot
Discordant
 
Join Date: Sep 2006
Location: Subsection 185.D354 C.12
Posts: 346
Default

I'm really happy that theres posting going on in my little corner of the Forum, but since it's in regard to GeargeS's tools; could all posts for GeargeS please be placed in GeargeS's section. I'm sure that would make his day.

Also, C#, J#, and VB.net are all the same engine. Anything done in one can be done in the others so long as there is a library for that particular syntax. Other wise the programmer would need to make a wrapper class which is a pain and why I only have three 3D engines available.

As for C++, enjoy Windows API and long compile times. I use VB.net because it's easy for me to read (Though I wish I could use C#/C++ comment methods, /* */ is cool for block comment.) and all the .net compile at a sickinly fast pace.
__________________
If at first you don't succeed destroy all evidence that you ever tried.

God doesn't give second chances... Hell, he sets you up the first time.
Reply With Quote
  #4  
Old 06-23-2008, 08:35 AM
nosfentora
Discordant
 
Join Date: Oct 2004
Location: In a house
Posts: 387
Default

Sorry bout the lack of code block Kayot - thanks for the edit!

also - for quick commenting in VB.NET - highlight the section you want to comment then CTRL+K+C to comment a block and CTRL+K+U to uncomment a block.
Reply With Quote
  #5  
Old 06-23-2008, 05:00 PM
Kayot
Discordant
 
Join Date: Sep 2006
Location: Subsection 185.D354 C.12
Posts: 346
Default

I know, thats block commenting. But that just put the ' symbol in front of every selected line. I like how /* is at the start and */ is at the end.
__________________
If at first you don't succeed destroy all evidence that you ever tried.

God doesn't give second chances... Hell, he sets you up the first time.
Reply With Quote
  #6  
Old 06-23-2008, 05:13 PM
nosfentora
Discordant
 
Join Date: Oct 2004
Location: In a house
Posts: 387
Default

Ahhh - gotcha.
Reply With Quote
  #7  
Old 06-25-2008, 09:37 PM
GeorgeS
Forum Guide
 
Join Date: Sep 2003
Location: California
Posts: 1,474
Default

Regarding the C++ and .net I've given vb.net a solid look over and decided since it's a steep learning curve, I will no longer continue upgrading and consider VB6 the last vb style language for me. I have finally decided it's C++ for me and find it easier in some ways since I already know much of the syntax - just have not used it in some time. I'll stay with vb6 and pick up C++ again.

In that front, I've already added a C++ spawning utility for the latest emu version (1100+) that "talks" to my tools and creates grids etc.. It's in testing but I would have to create a diff for integration as custom code. I've added several new commands that really assist in spawning npc's along grids easier than what's already in place. I may just compile a new zone.exe and give that out along with my tools.

Anyway, just thought you'all would want to know..

GeorgeS
__________________
Your source for EQ database tools
Toolshop is open for business


http://www.georgestools.chrsschb.com//
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 03:45 AM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3