Jump to content

LexaKAZAN

Members
  • Posts

    34
  • Credits

  • Joined

  • Last visited

  • Feedback

    0%

Everything posted by LexaKAZAN

  1. it doesn’t work for correction, for example, for Auto-Shots and Auto-Learning a lot will have to do heaps of crutches
  2. I have long solved the problem with Auto-Shots and Auto-Learning Skills https://cloud.mail.ru/public/QDek/2Nttte3Gi
  3. - L2Scripts, High Five Rev. 20720/2268 with GOD / Classic mod. $ 750.00 * send offer I also sell it, but only already finalized with a working study of skills, auto-shots, etc.
  4. public class MySqlConnect { Connection con = null; public MySqlConnect(String host, String port, String user, String password, String db, boolean console) throws Exception { try (Formatter form = new Formatter()) { Class.forName("org.mariadb.jdbc.Driver").getDeclaredConstructor().newInstance(); final String formattedText = form.format("jdbc:mariadb://%1$s:%2$s", host, port).toString(); con = DriverManager.getConnection(formattedText, user, password); try (Statement s = con.createStatement()) { s.execute("CREATE DATABASE IF NOT EXISTS `" + db + "`"); s.execute("USE `" + db + "`"); } } catch (SQLException e) { if (console) { e.printStackTrace(); } else { JOptionPane.showMessageDialog(null, "MySQL Error: " + e.getMessage(), "Connection Error", JOptionPane.ERROR_MESSAGE); } } catch (InstantiationException e) { if (console) { e.printStackTrace(); } else { JOptionPane.showMessageDialog(null, "Instantiation Exception: " + e.getMessage(), "Connection Error", JOptionPane.ERROR_MESSAGE); } } catch (IllegalAccessException e) { if (console) { e.printStackTrace(); } else { JOptionPane.showMessageDialog(null, "Illegal Access: " + e.getMessage(), "Connection Error", JOptionPane.ERROR_MESSAGE); } } catch (ClassNotFoundException e) { if (console) { e.printStackTrace(); } else { JOptionPane.showMessageDialog(null, "Cannot find MySQL Connector: " + e.getMessage(), "Connection Error", JOptionPane.ERROR_MESSAGE); } } } public Connection getConnection() { return con; } public Statement getStatement() { try { return con.createStatement(); } catch (SQLException e) { e.printStackTrace(); System.out.println("Statement Null"); return null; } } } under 12java MySqlConnect.java
  5. Do not even think to buy from them something the most slag of the team
×
×
  • Create New...