How to connect DHTMLX Scheduler with spring mvc hibernate and sql server
Null POINT EXEPTION
[code]<%@ page language=“java” contentType=“text/html; charset=UTF-8”
pageEncoding=“UTF-8”%>
.dhx_cal_event.event_math div,
.dhx_cal_event_line.event_math{
background-color: orange !important;
border-color: #a36800 !important;
}
.dhx_cal_event_clear.event_math{
color:orange !important;
}
.dhx_cal_event.event_science div, .dhx_cal_event_line.event_science{
background-color: #36BD14 !important;
border-color: #698490 !important;
}
.dhx_cal_event_clear.event_science{
color:#36BD14 !important;
}
.dhx_cal_event.event_english div, .dhx_cal_event_line.event_english{
background-color: #FC5BD5 !important;
border-color: #839595 !important;
}
.dhx_cal_event_clear.event_english{
color:#B82594 !important;
}
import java.sql.Connection;
import java.sql.DriverManager;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import com.dhtmlx.connector.ConnectorServlet;
import com.dhtmlx.connector.DBType;
import com.dhtmlx.connector.SchedulerConnector;
import com.dhtmlx.connector.ThreadSafeConnectorServlet;
public class BasicConnector extends ConnectorServlet {
public void configure() {
//obtain DB connection
try {
Connection conn=null;
// Class.forName ("net.sourceforge.jtds.jdbc.Driver").newInstance ();
conn = DriverManager.getConnection("jdbc:jtds:sqlserver://127.0.0.1:1433/Avocat1;instance=SQLEXPRESS;user=sa;password=123");
System.out.println("connected");
//Initialize connector
SchedulerConnector c = new SchedulerConnector(conn, DBType.MSSQL);
//c.servlet(req, res);
//configure used table and fields
c.set_encoding( "UTF-8" );
c.render_table("events", "id", "end_date,start_date,text");
System.out.println("maman");
}
catch (Throwable e) {
e.printStackTrace();
}
}
}[/code]