Example #1
0
    public string graphic()
    {
        String output = "";
        var param1 = Request.Params["param1"].ToString();
        //var param2 = Request.Params["param2"].ToString();
        //var param3 = Request.Params["param3"].ToString();
        //var param4 = Request.Params["param4"].ToString();
        //var param5 = Request.Params["param5"].ToString();
        //var param6 = Request.Params["param6"].ToString();

        try
        {
            LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
            eSTP.Datas();
            DataSet ds = new DataSet();
            ds = eSTP.List2("LANDCOMP.D_REPORT", param1, "");

            DataTable dt = new DataTable();
            dt = ds.Tables[0];

            for (int i = 0; i < dt.Rows.Count; i++)
            {
                output += (dt.Rows[i]["t_xmlxx"].ToString());
            }
        }
        catch (Exception e)
        {
            output = e.Message;
        }
        return output;
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "L":

                var param1L = Request.Params["param1"].ToString();

                LANDCOMP.ExecuteSTP eSTP_L = new LANDCOMP.ExecuteSTP();
                eSTP_L.Datas();
                DataSet ds_L = new DataSet();
                ds_L = eSTP_L.List7("P_GROUPS", param1L, "", "", "", "", "", "");

                dt = ds_L.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");

                groupsid = Session["groups"].ToString();

                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                    //Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["GroupIDents"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["GroupsNamess"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["GroupsLanjut"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["GroupsExcept"].ToString()) + "</cell>");

                    if (groupsid == "Operator")
                    {
                        Response.Write("<cell>" + RemoveWhiteSpace("View^PengecekanLapanganForm.aspx?rand=" + r.Next() + "&param1=V" + "&param2=" + dt.Rows[i]["GroupIDents"].ToString() + "") + "</cell>");

                    }
                    else
                    {

                        Response.Write("<cell>" + RemoveWhiteSpace("View^GroupManagementForm.aspx?rand=" + r.Next() + "&param1=V" + "&param2=" + dt.Rows[i]["GroupIDents"].ToString() + "") + "</cell>");
                        Response.Write("<cell>" + RemoveWhiteSpace("Edit^GroupManagementForm.aspx?rand=" + r.Next() + "&param1=E" + "&param2=" + dt.Rows[i]["GroupIDents"].ToString() + "") + "</cell>");
                        Response.Write("<cell>" + RemoveWhiteSpace("Delete^GroupManagementForm.aspx?rand=" + r.Next() + "&param1=D" + "&param2=" + dt.Rows[i]["GroupIDents"].ToString() + "") + "</cell>");
                    }
                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();

                Response.End();
                Response.End();

                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "L":

                var param1L = Request.Params["param1"].ToString();
                var param2L = Request.Params["param2"].ToString();
                var param4L = Request.Params["param4"].ToString();
                var param5L = Request.Params["param5"].ToString();
                LANDCOMP.ExecuteSTP eSTP_L = new LANDCOMP.ExecuteSTP();
                eSTP_L.Datas();
                DataSet ds_L = new DataSet();
                ds_L = eSTP_L.List34("P_REGIST", param1L, param2L, "", param4L, param5L, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "");

                dt = ds_L.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");

                groupsid = Session["groups"].ToString();

                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["praregNmrPra"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["registNmrReg"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["penlapNmrPen"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["registAssign"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["registLanjut"].ToString()) + "</cell>");

                    if (dt.Rows[i]["registNmrReg"].ToString() != "")
                    {
                        Response.Write("<cell>" + RemoveWhiteSpace("View^RegistrasiForm.aspx?rand=" + r.Next() + "&param1=V" + "&param2=" + dt.Rows[i]["registNmrReg"].ToString() + "") + "</cell>");
                        Response.Write("<cell>" + RemoveWhiteSpace("Edit^RegistrasiForm.aspx?rand=" + r.Next() + "&param1=E" + "&param2=" + dt.Rows[i]["registNmrReg"].ToString() + "") + "</cell>");
                        Response.Write("<cell>" + RemoveWhiteSpace("Delete^RegistrasiForm.aspx?rand=" + r.Next() + "&param1=D" + "&param2=" + dt.Rows[i]["registNmrReg"].ToString() + "") + "</cell>");
                    }
                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();

                Response.End();
                Response.End();

                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
Example #4
0
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "L":

                var param1L = Request.Params["param1"].ToString();
                var param2L = Request.Params["param2"].ToString();
                LANDCOMP.ExecuteSTP eSTP_L = new LANDCOMP.ExecuteSTP();
                eSTP_L.Datas();
                DataSet ds_L = new DataSet();
                ds_L = eSTP_L.List2("P_HOME", param1L, param2L);

                dt = ds_L.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");

                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["MidentNamass"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["registNmrReg"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["pengtoNmrPid"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["negosiNmrNeg"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["visumsNovism"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["berks1NmrBr1"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["pmbyrnNmrByr"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["berks2NmrBr2"].ToString()) + "</cell>");
                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();

                Response.End();
                Response.End();

                return false;

            case "graph":
                Response.ContentType = "application/xhtml+xml";
                Response.Write(graphic());
                Response.End();
                return false;
                break;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    public void HakAkses()
    {
        if (Session["userid"] is object)
        {
            userid = Session["userid"].ToString();

            if (Session["groups"] is object)
            {
                groups = Session["groups"].ToString();

            }

        }

        if (!(Session["userid"] is object))
        {
            Response.Write("<script language=\"javascript\" type=\"text/javascript\">");
            Response.Write("alert('Session sudah habis. Silakan login kembali.');");
            Response.Write("location.href = '../login.aspx';");
            Response.Write("</script>");
        }

        LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
        eSTP.Datas();
        DataSet ds = new DataSet();
        ds = eSTP.List8("P_MENU", "CHA", "", groups, "", "", "", "", "");
        dt = ds.Tables[0];

        PraRegistrasiView = dt.Rows[0]["PraRegistrasi"].ToString(); //0
        PraRegistrasiEdit = dt.Rows[0]["PraRegistrasiEdit"].ToString(); //1
        PraRegistrasiDelete = dt.Rows[0]["PraRegistrasiDelete"].ToString(); //2
        PraRegistrasiAssign = dt.Rows[0]["PraRegistrasiAssign"].ToString(); //3

        dt.Dispose();

        if (PraRegistrasiView.ToString() != "1" )
        {
            if (groups.ToString() != "1")
            {

                Response.Write("<script language=\"javascript\" type=\"text/javascript\">");
                //Response.Write("window.location.reload()");
                Response.Write("alert('Anda Tidak Memiliki Akses Untuk Melihat Modul Ini');");
                Response.Write("location.href = 'home.aspx';");
                Response.Write("</script>");
            }
        }
    }
    private void HakAkses()
    {
        if (Session["userid"] is object)
        {
            userid = Session["userid"].ToString();

            if (Session["groups"] is object)
            {
                groups = Session["groups"].ToString();

            }

        }

        LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
        eSTP.Datas();
        DataSet ds = new DataSet();

        ds = eSTP.List8("P_MENU", "CHA", "", groups, "", "", "", "", "");

        dt = ds.Tables[0];

        GroupManagementEdit = dt.Rows[9]["GroupManagementEdit"].ToString(); //0
        GroupManagementDelete = dt.Rows[9]["GroupManagementDelete"].ToString(); //1
        GroupManagementView = dt.Rows[9]["GroupManagement"].ToString(); //2
        GroupManagementAssign = dt.Rows[9]["GroupManagementAssign"].ToString(); //3

        dt.Dispose();

        if (GroupManagementView.ToString() != "1")
        {
            if (groups.ToString() != "1")
            {
                Response.Write("<script language=\"javascript\" type=\"text/javascript\">");
                Response.Write("alert('Anda Tidak Memiliki Akses Untuk Melihat Modul Ini');");
                Response.Write("location.href = 'home.aspx';");
                Response.Write("</script>");
            }
        }
    }
    private String SaveDetail()
    {
        String param1 = ""; if (Request.Params["param1"] is object) param1 = Request.Params["param1"].ToString();
        String param2 = ""; if (Request.Params["param2"] is object) param2 = Request.Params["param2"].ToString();
        String param3 = ""; if (Request.Params["param3"] is object) param3 = Request.Params["param3"].ToString();
        String param4 = ""; if (Request.Params["param4"] is object) param4 = Request.Params["param4"].ToString();
        String param5 = ""; if (Request.Params["param5"] is object) param5 = Request.Params["param5"].ToString();
        String param6 = ""; if (Request.Params["param6"] is object) param6 = Request.Params["param6"].ToString();
        String param7 = ""; if (Request.Params["param7"] is object) param7 = Request.Params["param7"].ToString();

        try
        {

                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                eSTP.save7("P_PENGTO_D", param1, param2, param3, param4, param5, param6, param7);

        }
        catch (Exception ex)
        {
            Response.Write(ex.Message);
            Response.End();
            return ex.Message;
        }

        return param1;
    }
Example #8
0
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "L":

                var param1L = Request.Params["param1"].ToString();
                var param2L = Request.Params["param2"].ToString();
                var param4L = Request.Params["param4"].ToString();
                LANDCOMP.ExecuteSTP eSTP_L = new LANDCOMP.ExecuteSTP();
                eSTP_L.Datas();
                DataSet ds_L = new DataSet();
                ds_L = eSTP_L.List8("P_VISUMS_D", param1L, param2L, "", param4L, "", "", "", "");
                dt = ds_L.Tables[0];
                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");

                    if (param1L == "LRK")
                    {
                        for (int i = 0; i < dt.Rows.Count; i++)
                        {
                            Random r = new Random();
                            Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                            Response.Write("<cell>" + (i + 1).ToString() + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["visumsCodess"].ToString()) + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["visumsKtrgn"].ToString()) + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["visumsRekom"].ToString()) + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["visumsAksi"].ToString()) + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["visumsSequen"].ToString()) + "</cell>");
                            Response.Write("</row>");
                        }
                    }

                    else
                    {
                        for (int i = 0; i < dt.Rows.Count; i++)
                        {
                            Random r = new Random();
                            Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                            Response.Write("<cell>" + (i + 1).ToString() + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["visumsCodess"].ToString()) + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["visumsKtrgn"].ToString()) + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace("Hapus^javascript:Hapus(\"" + "DO" + "\",\"" + "DO" + "\",\"" + dt.Rows[i]["visumsNovism"].ToString() + "\",\"" + dt.Rows[i]["visumsSequen"].ToString() + "\",\"" + "\");^_self") + "</cell>");
                            Response.Write("</row>");
                        }
                    }
                Response.Write("</rows>");
                dt.Dispose();
                Response.End();
                Response.End();

                return false;

            case "V":

                var Param1 = Request.Params["param1"].ToString();
                var Param2 = Request.Params["param2"].ToString();
                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                ds = eSTP.List11("P_VISUMS", Param1, Param2, "", "", "", "", "", "", "", "", "");

                dt = ds.Tables[0];

                Response.ContentType = "text/plain";
                Response.Write(dt.Rows[0]["visumsNovism"].ToString() + "|"); //0
                Response.Write(dt.Rows[0]["registNmrReg"].ToString() + "|"); //1
                Response.Write(dt.Rows[0]["pengtoNmrPid"].ToString() + "|"); //2
                Response.Write(dt.Rows[0]["visumsVerLnj"].ToString() + "|"); //3
                Response.Write(dt.Rows[0]["visumsEkseps"].ToString() + "|"); //4
                Response.Write(dt.Rows[0]["VisumsKetEks"].ToString() + "|"); //5
                dt.Dispose();

                Response.End();
                Response.End();
                return false;

            case "CRUD":
                Response.ContentType = "text/plain";
                Response.Write(Save());
                Response.End();
                return false;

            case "CRUDOS":
                Response.ContentType = "text/plain";
                Response.Write(SaveOS());
                Response.End();
                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    private String Save()
    {
        if (Session["userid"] is object)
        {
            userid = Session["userid"].ToString();

        }

        String param1 = ""; if (Request.Params["param1"] is object) param1 = Request.Params["param1"].ToString();
        String param2 = ""; if (Request.Params["param2"] is object) param2 = Request.Params["param2"].ToString();
        String param3 = ""; if (Request.Params["param3"] is object) param3 = Request.Params["param3"].ToString();
        String param4 = ""; if (Request.Params["param4"] is object) param4 = Request.Params["param4"].ToString();
        String param5 = ""; if (Request.Params["param5"] is object) param5 = Request.Params["param5"].ToString();
        String param6 = ""; if (Request.Params["param6"] is object) param6 = Request.Params["param6"].ToString();
        String param7 = ""; if (Request.Params["param7"] is object) param7 = Request.Params["param7"].ToString();
        String param8 = ""; if (Request.Params["param8"] is object) param8 = Request.Params["param8"].ToString();
        String param9 = ""; if (Request.Params["param9"] is object) param9 = Request.Params["param9"].ToString();
        String param10 = ""; if (Request.Params["param10"] is object) param10 = Request.Params["param10"].ToString();
        String param11 = ""; if (Request.Params["param11"] is object) param11 = Request.Params["param11"].ToString();
        String param12 = ""; if (Request.Params["param12"] is object) param12 = Request.Params["param12"].ToString();
        String param13 = ""; if (Request.Params["param13"] is object) param13 = Request.Params["param13"].ToString();
        String param14 = ""; if (Request.Params["param14"] is object) param14 = Request.Params["param14"].ToString();
        String param15 = ""; if (Request.Params["param15"] is object) param15 = Request.Params["param15"].ToString();
        String param16 = ""; if (Request.Params["param16"] is object) param16 = Request.Params["param16"].ToString();
        String param17 = ""; if (Request.Params["param17"] is object) param17 = Request.Params["param17"].ToString();
        String param18 = ""; if (Request.Params["param18"] is object) param18 = Request.Params["param18"].ToString();
        String param19 = ""; if (Request.Params["param19"] is object) param19 = Request.Params["param19"].ToString();
        String param20 = ""; if (Request.Params["param20"] is object) param20 = Request.Params["param20"].ToString();
        String param21 = ""; if (Request.Params["param21"] is object) param21 = Request.Params["param21"].ToString();
        String param22 = ""; if (Request.Params["param22"] is object) param22 = Request.Params["param22"].ToString();
        String sql = "";
        String output = "";

        try
        {

            output = param1;

            if (output == "E" || output == "D" || output == "A")
            {
                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                ds = eSTP.List22("P_PENGTO", "X", param2, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "");
                dt = ds.Tables[0];

                if (dt.Rows.Count > 0)
                {
                    if (output == "E")
                        output = "noedit";

                    if (output == "D")
                        output = "nodelete";

                    if (output == "A")
                        output = "noadd";

                    return output;
                }
            }
            //if (output == "E" )
            //{
            //    LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
            //    eSTP.Datas();
            //    DataSet ds = new DataSet();
            //    ds = eSTP.List22("P_PENGTO", "Z", param2, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "");
            //    dt = ds.Tables[0];

            //    if (dt.Rows.Count > 0)
            //    {
            //        output = "Z";

            //        return output;
            //    }
            //}

            if (output == "I" || output == "E" || output == "D")
            {

                param17 = userid;

                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                eSTP.save22("P_PENGTO", param1, param2, param3, param4, param5, param6, param7, param8, param9, param10, param11, param12, param13, param14, param15, param16, userid, param18, param19, param20, param21, param22);

                return output;
            }
            else
                output = "gagal";
        }
        catch (Exception ex)
        {
            Response.Write(ex.Message);
            Response.End();
            return ex.Message;
        }

        return output;
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "V":
                var Param1 = Request.Params["param1"].ToString();
                var Param2 = Request.Params["param2"].ToString();
                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                ds = eSTP.List13("P_PENLAP", Param1, Param2, "", "", "", "", "", "", "", "", "", "", "");

                dt = ds.Tables[0];

                Response.ContentType = "text/plain";
                Response.Write(dt.Rows[0]["penlapNmrPen"].ToString() + "|"); //
                Response.Write(dt.Rows[0]["penlapDatess"].ToString() + "|"); //1
                Response.Write(dt.Rows[0]["penlapTglukr"].ToString() + "|"); //2
                Response.Write(dt.Rows[0]["penlapTglJdw"].ToString() + "|"); //3
                Response.Write(dt.Rows[0]["praregNmrPra"].ToString() + "|"); //4
                Response.Write(dt.Rows[0]["penlapKtngan"].ToString() + "|"); //5
                Response.Write(dt.Rows[0]["penlapLanjut"].ToString() + "|"); //6
                Response.Write(dt.Rows[0]["PenlapEkspsi"].ToString() + "|"); //7
                Response.Write(dt.Rows[0]["penlapKeteks"].ToString() + "|"); //8
                Response.Write(dt.Rows[0]["penlapUserid"].ToString() + "|"); //9
                Response.Write(dt.Rows[0]["penlapUserdt"].ToString() + "|"); //10
                Response.Write(dt.Rows[0]["penlapAssign"].ToString() + "|"); //11
                Response.Write(dt.Rows[0]["praregNmrPra"].ToString() + "|"); //12
                Response.Write(dt.Rows[0]["praregLokkab"].ToString() + "|"); //13
                Response.Write(dt.Rows[0]["praregLokkec"].ToString() + "|"); //14
                Response.Write(dt.Rows[0]["praregLokdes"].ToString() + "|"); //15
                Response.Write(dt.Rows[0]["MidentNamass"].ToString() + "|"); //16

                dt.Dispose();

                Response.End();
                Response.End();
                return false;

            //return false;

            case "CRUD":
                Response.ContentType = "text/plain";
                Response.Write(Save());
                Response.End();
                return false;

            case "df":
                Response.Clear();
                string namafile = (Request.Params["filelama"] is object ? Request.Params["filelama"].ToString() : "");
                String urlfile = (Request.Params["namafile"] is object ? Request.Params["namafile"].ToString() : "");
                String randomfile = (Request.Params["random"] is object ? Request.Params["random"].ToString() : "");
                string type = "";
                switch (namafile.Substring(namafile.Length - 4))
                {
                    case ".htm":
                    case ".html":
                        type = "text/HTML";
                        break;

                    case ".txt":
                        type = "text/plain";
                        break;

                    case ".doc":
                    case ".docx":
                    case ".rtf":
                        type = "Application/msword";
                        break;
                    case ".xls":
                    case ".xlsx":
                        type = "Application/msexcel";
                        break;

                    case ".zip":
                    case ".rar":
                        type = "application/zip";
                        break;

                    case ".pdf":
                        type = "application/pdf";
                        break;
                    case ".jpg":
                        type = "image/JPG";
                        break;
                    case ".pgn":
                        type = "image/PNG";
                        break;
                    case ".tif":
                        type = "image/tif";
                        break;
                }

                Response.AddHeader("content-disposition", "attachment;filename=" + namafile + "");
                Response.ContentType = type;

                Response.WriteFile(Server.MapPath(@"~/uploaddocument/" + Request.Params["namafile"].ToString().Replace("&amp;", "&")));

                Response.End();
                return false;
                break;

            case "SavePic":
                Response.ContentType = "text/plain";
                Response.Write(SaveUploadPengecekan());
                Response.End();
                return false;

            case "DOCpic":

                String path_pic = (HttpContext.Current.Request.Url.AbsolutePath).ToLower();

                string IDPengecekan = Request.Params["IDPengecekan"].ToString();
                string param1 = Request.Params["param1"].ToString();

                LANDCOMP.ExecuteSTP eSTPx = new LANDCOMP.ExecuteSTP();
                eSTPx.Datas();
                DataSet dsx = new DataSet();
                dsx = eSTPx.List5("P_PENLAP_D", param1, IDPengecekan, "", "", "");

                dt = dsx.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");

                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["codessDescs1"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["penlapKetera"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumFiless"].ToString()) + "</cell>");

                    Response.Write("<cell>" + "Download^" + path_pic + "?sm=df&amp;namafile=" + dt.Rows[i]["hdocumIdLink"].ToString() + "&amp;filelama=" + dt.Rows[i]["hdocumFiless"].ToString() + "</cell>");
                    //Response.Write("<cell>" + "Delete^" + path_pic + "?sm=Deletepic&amp;IDSOURCE=" + dt.Rows[i]["IDSource"].ToString() + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace("Delete^javascript:DeletePic(\"" + dt.Rows[i]["hdocumIdLink"].ToString()) + "\",\"" + IDPengecekan + "\");^_self" + "</cell>");

                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumIdSour"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumIdLink"].ToString()) + "</cell>");

                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();
                Response.End();

                return false;
            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
Example #11
0
    private String SaveOS()
    {
        String param1 = ""; if (Request.Params["param1"] is object) param1 = Request.Params["param1"].ToString();
        String param2 = ""; if (Request.Params["param2"] is object) param2 = Request.Params["param2"].ToString();
        String param3 = ""; if (Request.Params["param3"] is object) param3 = Request.Params["param3"].ToString();
        String param4 = ""; if (Request.Params["param4"] is object) param4 = Request.Params["param4"].ToString();
        String param5 = ""; if (Request.Params["param5"] is object) param5 = Request.Params["param5"].ToString();
        String param6 = ""; if (Request.Params["param6"] is object) param6 = Request.Params["param6"].ToString();
        String param7 = ""; if (Request.Params["param7"] is object) param7 = Request.Params["param7"].ToString();
        String param8 = ""; if (Request.Params["param8"] is object) param8 = Request.Params["param8"].ToString();
        //String sql = "";
        String output = "";

        try
        {
            output = param1;

            if (output == "I" || output == "DO" || output == "IR")
            {

                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                eSTP.save8("P_VISUMS_D", param1, param2, param3, param4, param5, param6, param7, param8);

                return output;
            }

            else
                output = "gagal";
        }
        catch (Exception ex)
        {
            Response.Write(ex.Message);
            Response.End();
            return ex.Message;
        }

        return output;
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "E":

                Response.ContentType = "text/plain";
                var param1 = Request.Params["param1"].ToString();
                var param2 = Request.Params["param2"].ToString();
                var param4 = Request.Params["param4"].ToString();
                var param5 = Request.Params["param5"].ToString();
                var param6 = Request.Params["param6"].ToString();
                var param7 = Request.Params["param7"].ToString();
                var param12 = Request.Params["param12"].ToString();
                var param13 = Session["userid"].ToString();
                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                eSTP.save14("P_BERKS1", param1, param2, "", param4, param5, param6, param7, "", "", "", "", param12, param13, "");
                Response.End();
                return false;

            case "L":

                var param1L = Request.Params["param1"].ToString();
                var param2L = Request.Params["param2"].ToString();
                var param4L = Request.Params["param4"].ToString();
                var param5L = Request.Params["param5"].ToString();
                LANDCOMP.ExecuteSTP eSTP_L = new LANDCOMP.ExecuteSTP();
                eSTP_L.Datas();
                DataSet ds_L = new DataSet();
                ds_L = eSTP_L.List14("P_BERKS1", param1L, param2L, "", param4L, param5L, "", "", "", "", "", "", "", "", "");

                dt = ds_L.Tables[0];
                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["berks1NmrBr1"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["pengtoNmrPid"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["negosiNmrReg"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["visumsNovism"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["berks1Assign"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["berks1Lanjut"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["Assign"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["negosiNmrNeg"].ToString()) + "</cell>");
                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();

                Response.End();
                Response.End();

                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    private String SaveUploadRegistrasi()
    {
        string IDRegistrasi = Request.Params["IDREGISTRASI"].ToString();
         string _stNamaFile = Request.Params["NAMA"].ToString();
         string _stKeterangan = Request.Params["KETERANGAN"].ToString();
         string _stNomor = Request.Params["NOMOR"].ToString();

         LANDCOMP.UploadFile uf = new LANDCOMP.UploadFile();
         uf.Datas();

         string _stDates = DateTime.Today.ToString("yyyyMMdd");

         string param1 = Request.Params["param1"].ToString();
         string param5 = Request.Params["param5"].ToString();
         string user = Request.Params["user"].ToString();
         string wilayah = Request.Params["wilay"].ToString();

         string _stUploadKeterangan = "";
         _stUploadKeterangan = _stKeterangan;

         string uploadFolder = Request.PhysicalApplicationPath + "uploadDocument\\";
         string extension = Path.GetExtension(_stNamaFile);

         LANDCOMP.paramz ext = new LANDCOMP.paramz();

         LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
         eSTP.Datas();
         DataSet ds = new DataSet();

         //eSTP.save5("P_REGIST_U", param1, IDRegistrasi, "", param5, _stKeterangan);

         if (extension != ".exe")
         {

             uf.UploadFilesWeb("I", user, _stDates, "Master Identitas", param5, uploadFolder, IDRegistrasi, _stNomor + extension, _stNamaFile, _stUploadKeterangan);
         }

         var _stOutput = IDRegistrasi;

         return _stOutput;
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "select":

                var Param1 = Request.Params["param1"].ToString();
                var Param2 = Request.Params["param2"].ToString();

                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                ds = eSTP.select9("landcomp.P_PRAREG", Param1, Param2, "", "", "", "", "", "","");

                dt = ds.Tables[0];

                Response.ContentType = "text/plain";

                Response.Write(dt.Rows[0]["praregNmrPra"].ToString() + "|"); //0
                Response.Write(dt.Rows[0]["praregIdents"].ToString() + "|"); //1
                Response.Write(dt.Rows[0]["MidentNamass"].ToString() + "|"); //2
                Response.Write(dt.Rows[0]["MidentJnsKel"].ToString() + "|"); //3
                Response.Write(dt.Rows[0]["MidentTmplhr"].ToString() + "|"); //4
                Response.Write(dt.Rows[0]["MidentTgllhr"].ToString() + "|"); //5
                Response.Write(dt.Rows[0]["MidentPekerj"].ToString() + "|"); //6
                Response.Write(dt.Rows[0]["MidentAlamat"].ToString() + "|"); //7
                Response.Write(dt.Rows[0]["MidentNmrHps"].ToString() + "|"); //8
                Response.Write(dt.Rows[0]["MidentJnsIdn"].ToString() + "|"); //9
                Response.Write(dt.Rows[0]["praregLokkab"].ToString() + "|"); //10
                Response.Write(dt.Rows[0]["praregLokkec"].ToString() + "|"); //11
                Response.Write(dt.Rows[0]["praregLokdes"].ToString() + "|"); //12
                Response.Write(dt.Rows[0]["praregLanjut"].ToString() + "|"); //13

                dt.Dispose();

                Response.End();
                Response.End();
                return false;

            case "Save":
                Response.ContentType = "text/plain";
                Response.Write(Save());
                Response.End();
                return false;

            case "Delete":
                Response.ContentType = "text/plain";
                Response.Write(Delete());
                Response.End();
                return false;

            case "dd":
                Response.ContentType = "text/plain";
                Response.Write(Admin());
                Response.End();
                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    public void HakAkses()
    {
        if (Session["userid"] is object)
        {
            userid = Session["userid"].ToString();

            if (Session["groups"] is object)
            {
                groups = Session["groups"].ToString();

            }

        }

        if (!(Session["userid"] is object))
        {
            Response.Write("<script language=\"javascript\" type=\"text/javascript\">");
            Response.Write("alert('Session sudah habis. Silakan login kembali.');");
            Response.Write("location.href = '../login.aspx';");
            Response.Write("</script>");
        }

        LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
        eSTP.Datas();
        DataSet ds = new DataSet();

        var Param1 = "";

        bool cek = true;
        if (cek && (Request.Params["param1"] is object))
        {
            Param1 = Request.Params["param1"].ToString();
        }
        else
        {
            Param1 = "";
        }

        ds = eSTP.List8("P_MENU", "CHA", "", groups, "", "", "", "", "");
        dt = ds.Tables[0];

        MasterIdentitasView = dt.Rows[11]["MasterIdentitas"].ToString(); //0
        MasterIdentitasEdit = dt.Rows[11]["MasterIdentitasEdit"].ToString(); //1
        MasterIdentitasDelete = dt.Rows[11]["MasterIdentitasDelete"].ToString(); //2
        MasterIdentitasAssign = dt.Rows[11]["MasterIdentitasAssign"].ToString(); //3

        dt.Dispose();

        if (Param1 == "")
        {
            if (MasterIdentitasView.ToString() != "1")
            {
                if (groups.ToString() != "1")
                {
                    Response.Write("<script language=\"javascript\" type=\"text/javascript\">");
                    Response.Write("alert('Anda Tidak Memiliki Akses Untuk Menambah Di Modul Ini');");
                    Response.Write("location.href = 'home.aspx';");
                    Response.Write("</script>");
                }
            }
        }

        else if (Param1 == "F")
        {
            if (MasterIdentitasView.ToString() != "1")
            {
                if (groups.ToString() != "1")
                {
                    Response.Write("<script language=\"javascript\" type=\"text/javascript\">");
                    Response.Write("alert('Anda Tidak Memiliki Akses Untuk Melihat Di Modul Ini');");
                    Response.Write("location.href = 'home.aspx';");
                    Response.Write("</script>");
                }
            }
        }

        else if (Param1 == "E")
        {
            if (MasterIdentitasEdit.ToString() != "1")
            {
                if (groups.ToString() != "1")
                {
                    Response.Write("<script language=\"javascript\" type=\"text/javascript\">");
                    Response.Write("alert('Anda Tidak Memiliki Akses Untuk Edit Di Modul Ini');");
                    Response.Write("location.href = 'home.aspx';");
                    Response.Write("</script>");
                }
            }
        }

        else if (Param1.ToString() == "D")
        {
            if (MasterIdentitasDelete.ToString() != "1")
            {
                if (groups.ToString() != "1")
                {
                    Response.Write("<script language=\"javascript\" type=\"text/javascript\">");
                    Response.Write("alert('Anda Tidak Memiliki Akses Untuk Delete Di Modul Ini');");
                    Response.Write("location.href = 'home.aspx';");
                    Response.Write("</script>");
                }
            }
        }

        else if (Param1.ToString() == "I")
        {
            if (MasterIdentitasAssign.ToString() != "1")
            {
                if (groups.ToString() != "1")
                {
                    Response.Write("<script language=\"javascript\" type=\"text/javascript\">");
                    Response.Write("alert('Anda Tidak Memiliki Akses Untuk Menambah Di Modul Ini');");
                    Response.Write("location.href = 'home.aspx';");
                    Response.Write("</script>");
                }
            }
        }
        else
        {
            Response.Write("<script language=\"javascript\" type=\"text/javascript\">");
            Response.Write("alert('Aksi Yang Anda Cari Tidak Ditemukan');");
            Response.Write("location.href = 'home.aspx';");
            Response.Write("</script>");
        }
    }
Example #16
0
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "HA":

                if (Session["userid"] is object)
                {
                    userid = Session["userid"].ToString();

                }

                //Response.ContentType = "text/plain";
                var param1 = Request.Params["param1"].ToString();
                var param2 = Request.Params["param2"].ToString();
                var param3 = Request.Params["param3"].ToString();
                var param4 = Request.Params["param4"].ToString();
                var param5 = Request.Params["param5"].ToString();
                var param6 = Request.Params["param6"].ToString();
                var param7 = Session["userid"].ToString();
                var param8 = Request.Params["param8"].ToString();

                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                //DataSet ds = new DataSet();
                eSTP.save8("P_MENU", param1, param2, param3, param4, param5, param6, userid, param8);
                //Response.End();
                return false;

            case "L":

                var param1L = Request.Params["param1"].ToString();
                var param2L = Request.Params["param2"].ToString();
                var param3L = Request.Params["param3"].ToString();

                LANDCOMP.ExecuteSTP eSTP_L = new LANDCOMP.ExecuteSTP();
                eSTP_L.Datas();
                DataSet ds_L = new DataSet();
                ds_L = eSTP_L.List8("P_MENU", param1L, param2L, param3L, "", "", "", "", "");

                dt = ds_L.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");

                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["Modul"].ToString()) + "</cell>");

                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["Ad"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["Edit"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["Delet"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["Vie"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["Prin"].ToString()) + "</cell>");
                    //Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["negosiSepakt"].ToString()) + "</cell>");
                    //Response.Write("<cell>" + RemoveWhiteSpace("View^NegosiasiForm.aspx?rand=" + r.Next() + "&param1=V" + "&param2=" + dt.Rows[i]["registNmrReg"].ToString() + "") + "</cell>");
                    //if (dt.Rows[i]["negosiNmrNeg"].ToString() != "")
                    //{

                    //    Response.Write("<cell>" + RemoveWhiteSpace("Edit^NegosiasiForm.aspx?rand=" + r.Next() + "&param1=E" + "&param2=" + dt.Rows[i]["registNmrReg"].ToString() + "") + "</cell>");
                    //    Response.Write("<cell>" + RemoveWhiteSpace("Delete^NegosiasiForm.aspx?rand=" + r.Next() + "&param1=D" + "&param2=" + dt.Rows[i]["registNmrReg"].ToString() + "") + "</cell>");
                    //}
                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();
                Response.End();
                Response.End();

                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    private String Admin()
    {
        var Param1 = Request.Params["param1"].ToString();
        var Param2 = Request.Params["param2"].ToString();
        string output = "";

        try
        {
            LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
            eSTP.Datas();
            DataSet ds = new DataSet();
            ds = eSTP.List2("landcomp.C_ADMINS", Param1, Param2);

            dt = ds.Tables[0];

            for (int i = 0; i < dt.Rows.Count; i++)
            {
                output += dt.Rows[i]["namass"].ToString() + "|";
                output += dt.Rows[i]["idents"].ToString() + "*";
            }
            dt.Dispose();
        }
        catch (Exception ex)
        {
            Response.Write(ex.Message);
        }
        return output;
    }
    private String Save()
    {
        //string strCon = System.Configuration.ConfigurationManager.ConnectionStrings["ConStrLANDCOMPLocal2"].ToString();

        //conn2 = new Connection(strCon);

        String param1 = ""; if (Request.Params["param1"] is object) param1 = Request.Params["param1"].ToString();
        String param2 = ""; if (Request.Params["param2"] is object) param2 = Request.Params["param2"].ToString();
        String param3 = ""; if (Request.Params["param3"] is object) param3 = Request.Params["param3"].ToString();
        String param4 = ""; if (Request.Params["param4"] is object) param4 = Request.Params["param4"].ToString();
        String param5 = ""; if (Request.Params["param5"] is object) param5 = Request.Params["param5"].ToString();
        String param6 = ""; if (Request.Params["param6"] is object) param6 = Request.Params["param6"].ToString();
        String param7 = ""; if (Request.Params["param7"] is object) param7 = Request.Params["param7"].ToString();
        String param8 = ""; if (Request.Params["param8"] is object) param8 = Request.Params["param8"].ToString();
        String param9 = ""; if (Request.Params["param9"] is object) param9 = Request.Params["param9"].ToString();
        String param10 = ""; if (Request.Params["param10"] is object) param10 = Request.Params["param10"].ToString();
        String param11 = ""; if (Request.Params["param11"] is object) param11 = Request.Params["param11"].ToString();
        String param12 = ""; if (Request.Params["param12"] is object) param12 = Request.Params["param12"].ToString();
        String param13 = ""; if (Request.Params["param13"] is object) param13 = Request.Params["param13"].ToString();
        //String sql = "";
        String output = "";

           try
        {
              output = param1;

              if (output == "E" || output == "D" || output == "A")
              {
                  LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                  eSTP.Datas();
                  DataSet ds = new DataSet();
                  ds = eSTP.List13("P_NEGOSI", "X", param2, "", "", "", "", "", "", "", "", "", "", "");
                  dt = ds.Tables[0];

                  if (dt.Rows.Count > 0)
                  {
                      if (output == "E")
                          output = "noedit";

                      if (output == "D")
                          output = "nodelete";

                      if (output == "A")
                          output = "noadd";

                      return output;
                  }
              }

            if (output == "I" ||  output == "E" || output == "D")
            {
                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                eSTP.save13("P_NEGOSI", param1, param2, param3, param4, param5, param6, param7, param8, param9, param10, param11, param12, param13);

                return output;
            }
            else
                output = "gagal";
        }
        catch (Exception ex)
        {
            Response.Write(ex.Message);
            Response.End();
            return ex.Message;
        }

        return output;
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "L":

                var param1L = Request.Params["param1"].ToString();
                var param2L = Request.Params["param2"].ToString();
                LANDCOMP.ExecuteSTP eSTP_L = new LANDCOMP.ExecuteSTP();
                eSTP_L.Datas();
                DataSet ds_L = new DataSet();
                ds_L = eSTP_L.List9("P_NEGOSI_D", param1L, param2L, "", "", "", "", "", "", "");
                dt = ds_L.Tables[0];
                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["negosiDatess"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["negosiObjeks"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["negosiLuasss"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["negosiHMinta"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["negosiJHMinta"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["negosiHTawar"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["negosiJHTawar"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["Selisih"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["negosiSequen"].ToString()) + "</cell>");
                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();

                Response.End();
                Response.End();
                return false;

            case "V":
                Response.ContentType = "text/plain";
                var Param1 = Request.Params["param1"].ToString();
                var Param2 = Request.Params["param2"].ToString();

                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();

                ds = eSTP.List13("P_NEGOSI", Param1, Param2, "", "", "", "", "", "", "", "", "", "", "");

                dt = ds.Tables[0];

                Response.ContentType = "text/plain";
                Response.Write(dt.Rows[0]["negosiNmrNeg"].ToString() + "|"); //0
                Response.Write(dt.Rows[0]["registNmrReg"].ToString() + "|"); //1
                Response.Write(dt.Rows[0]["pengtoNmrPid"].ToString() + "|"); //2
                Response.Write(dt.Rows[0]["negosiKetrgn"].ToString() + "|"); //3
                Response.Write(dt.Rows[0]["negosiSepakt"].ToString() + "|"); //4
                Response.Write(dt.Rows[0]["negosiSKGR"].ToString() + "|"); //5
                Response.Write(dt.Rows[0]["negosiKetEks"].ToString() + "|"); //6
                Response.Write(dt.Rows[0]["negosiEkseps"].ToString() + "|"); //7
                Response.Write(dt.Rows[0]["minta"].ToString() + "|"); //8
                Response.Write(dt.Rows[0]["tawar"].ToString() + "|"); //9
                Response.Write(dt.Rows[0]["tglNego"].ToString() + "|"); //10

                dt.Dispose();
                Response.End();
                Response.End();
                return false;

            case "I":

                String param1 = ""; if (Request.Params["param1"] is object) param1 = Request.Params["param1"].ToString();
                String param2 = ""; if (Request.Params["param2"] is object) param2 = Request.Params["param2"].ToString();
                String param3 = ""; if (Request.Params["param3"] is object) param3 = Request.Params["param3"].ToString();
                String param4 = ""; if (Request.Params["param4"] is object) param4 = Request.Params["param4"].ToString();
                String param5 = ""; if (Request.Params["param5"] is object) param5 = Request.Params["param5"].ToString();
                String param6 = ""; if (Request.Params["param6"] is object) param6 = Request.Params["param6"].ToString();
                String param7 = ""; if (Request.Params["param7"] is object) param7 = Request.Params["param7"].ToString();
                String param8 = ""; if (Request.Params["param8"] is object) param8 = Request.Params["param8"].ToString();
                String param9 = ""; if (Request.Params["param9"] is object) param9 = Request.Params["param9"].ToString();
                String sql = "";
                String output = "";

                LANDCOMP.ExecuteSTP eSTP_IA = new LANDCOMP.ExecuteSTP();
                eSTP_IA.Datas();
                eSTP_IA.save9("P_NEGOSI_D", param1, param2, param3, param4, param5, param6, param7, param8, param9);

                return false;

            case "CRUD":
                Response.ContentType = "text/plain";
                Response.Write(Save());
                Response.End();
                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "L":

                HakAkses();
                var param1L = Request.Params["param1"].ToString();
                var param2L = Request.Params["param2"].ToString();
                var param4L = Request.Params["param4"].ToString();
                var param5L = Request.Params["param5"].ToString();
                LANDCOMP.ExecuteSTP eSTP_L = new LANDCOMP.ExecuteSTP();
                eSTP_L.Datas();
                DataSet ds_L = new DataSet();
                ds_L = eSTP_L.select9("P_PRAREG", param1L, param2L, "", param4L, param5L, "", "", "", "");

                dt = ds_L.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");

                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["praregNmrPra"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["MidentIdents"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["MidentNamass"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["praregLokkab"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["praregLokkec"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["praregLokdes"].ToString()) + "</cell>");

                    if (dt.Rows[i]["praregNmrPra"].ToString() != "")
                    {

                        if (groups.ToString() == "1")
                        {
                            Response.Write("<cell>" + RemoveWhiteSpace("View^PraregistrasiForm.aspx?rand=" + r.Next() + "&param1=V" + "&param2=" + dt.Rows[i]["MidentIdents"].ToString() + "") + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace("Edit^PraregistrasiForm.aspx?rand=" + r.Next() + "&param1=E" + "&param2=" + dt.Rows[i]["MidentIdents"].ToString() + "") + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace("Delete^PraregistrasiForm.aspx?rand=" + r.Next() + "&param1=D" + "&param2=" + dt.Rows[i]["MidentIdents"].ToString() + "") + "</cell>");
                        }
                        else
                        {
                            //if (dt.Rows[i]["pengtoLanjut"].ToString() != "Lanjut")
                            //{
                                if (PraRegistrasiView.ToString() == "1")
                                {
                                    Response.Write("<cell>" + RemoveWhiteSpace("View^PraregistrasiForm.aspx?rand=" + r.Next() + "&param1=V" + "&param2=" + dt.Rows[i]["MidentIdents"].ToString() + "") + "</cell>");
                                }
                                if (PraRegistrasiEdit.ToString() == "1")
                                {
                                    Response.Write("<cell>" + RemoveWhiteSpace("Edit^PraregistrasiForm.aspx?rand=" + r.Next() + "&param1=E" + "&param2=" + dt.Rows[i]["MidentIdents"].ToString() + "") + "</cell>");
                                }

                                if (PraRegistrasiDelete.ToString() == "1")
                                {
                                    Response.Write("<cell>" + RemoveWhiteSpace("Delete^PraregistrasiForm.aspx?rand=" + r.Next() + "&param1=D" + "&param2=" + dt.Rows[i]["MidentIdents"].ToString() + "") + "</cell>");
                                }
                            //}
                        }

                    }

                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();

                Response.End();

                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "V":

                var Param1 = Request.Params["param1"].ToString();
                var Param2 = Request.Params["param2"].ToString();
                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                ds = eSTP.List22("P_PENGTO", Param1, Param2, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "");

                dt = ds.Tables[0];

                Response.ContentType = "text/plain";
                Response.Write(dt.Rows[0]["pengtoNmrPid"].ToString() + "|"); //0
                Response.Write(dt.Rows[0]["pengtoDatess"].ToString() + "|"); //1
                Response.Write(dt.Rows[0]["registNmrReg"].ToString() + "|"); //2
                Response.Write(dt.Rows[0]["pengtoTgljdw"].ToString() + "|"); //3
                Response.Write(dt.Rows[0]["MidentNamass"].ToString() + "|"); //4
                Response.Write(dt.Rows[0]["MidentIdents"].ToString() + "|"); //5
                Response.Write(dt.Rows[0]["MidentNmrHps"].ToString() + "|"); //6
                Response.Write(dt.Rows[0]["MidentAlamat"].ToString() + "|"); //7
                Response.Write(dt.Rows[0]["registDatess"].ToString() + "|"); //8
                Response.Write(dt.Rows[0]["pengtoKeteks"].ToString() + "|"); //9
                Response.Write(dt.Rows[0]["pengtoEkseps"].ToString() + "|"); //10
                Response.Write(dt.Rows[0]["pengtoTglpen"].ToString() + "|"); //11
                Response.Write(dt.Rows[0]["pengtoToLMss"].ToString() + "|"); //12
                Response.Write(dt.Rows[0]["pengtoToSurv"].ToString() + "|"); //13
                Response.Write(dt.Rows[0]["pengtoAppsur"].ToString() + "|"); //14
                Response.Write(dt.Rows[0]["pengtoAppTss"].ToString() + "|"); //15
                Response.Write(dt.Rows[0]["pengtoDiteri"].ToString() + "|"); //16
                Response.Write(dt.Rows[0]["pengtoKtergn"].ToString() + "|"); //17
                Response.Write(dt.Rows[0]["pengtoLanjut"].ToString() + "|"); //18
                Response.Write(dt.Rows[0]["pengtoOverlp"].ToString() + "|"); //19
                Response.Write(dt.Rows[0]["pengtoIdents"].ToString() + "|"); //20
                Response.Write(dt.Rows[0]["pengtoNamPLK"].ToString() + "|"); //21
                Response.Write(dt.Rows[0]["pengtoLuasPL"].ToString() + "|"); //22

                dt.Dispose();

                Response.End();
                Response.End();
                return false;

            //return false;

            case "CRUD":
                Response.ContentType = "text/plain";
                Response.Write(Save());
                Response.End();
                return false;

            case "ID":
                Response.ContentType = "text/plain";
                Response.Write(SaveDetail());
                Response.End();
                return false;

            case "df":
                Response.Clear();
                string namafile = (Request.Params["filelama"] is object ? Request.Params["filelama"].ToString() : "");
                String urlfile = (Request.Params["namafile"] is object ? Request.Params["namafile"].ToString() : "");
                String randomfile = (Request.Params["random"] is object ? Request.Params["random"].ToString() : "");
                string type = "";
                switch (namafile.Substring(namafile.Length - 4))
                {
                    case ".htm":
                    case ".html":
                        type = "text/HTML";
                        break;

                    case ".txt":
                        type = "text/plain";
                        break;

                    case ".doc":
                    case ".docx":
                    case ".rtf":
                        type = "Application/msword";
                        break;
                    case ".xls":
                    case ".xlsx":
                        type = "Application/msexcel";
                        break;

                    case ".zip":
                    case ".rar":
                        type = "application/zip";
                        break;

                    case ".pdf":
                        type = "application/pdf";
                        break;
                    case ".jpg":
                        type = "image/JPG";
                        break;
                    case ".pgn":
                        type = "image/PNG";
                        break;
                    case ".tif":
                        type = "image/tif";
                        break;
                }

                Response.AddHeader("content-disposition", "attachment;filename=" + namafile + "");
                Response.ContentType = type;

                Response.WriteFile(Server.MapPath(@"~/uploaddocument/" + Request.Params["namafile"].ToString().Replace("&amp;", "&")));

                Response.End();
                return false;
                break;

            case "SavePic":
                Response.ContentType = "text/plain";
                Response.Write(SaveUploadGIFDUMP());
                Response.End();
                return false;

            case "DOCpic":

                String path_pic = (HttpContext.Current.Request.Url.AbsolutePath).ToLower();

                string IDREGISTRASI = Request.Params["IDREGISTRASI"].ToString();
                string param1 = Request.Params["param1"].ToString();

                LANDCOMP.ExecuteSTP eSTPx = new LANDCOMP.ExecuteSTP();
                eSTPx.Datas();
                DataSet dsx = new DataSet();
                dsx = eSTPx.List22("P_PENGTO", param1, IDREGISTRASI, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "");

                dt = dsx.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");

                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumFiless"].ToString()) + "</cell>");

                    Response.Write("<cell>" + "Download^" + path_pic + "?sm=df&amp;namafile=" + dt.Rows[i]["hdocumIdLink"].ToString() + "&amp;filelama=" + dt.Rows[i]["hdocumFiless"].ToString() + "</cell>");
                    //Response.Write("<cell>" + "Delete^" + path_pic + "?sm=Deletepic&amp;IDSOURCE=" + dt.Rows[i]["IDSource"].ToString() + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace("Delete^javascript:DeletePic(\"" + dt.Rows[i]["hdocumIdLink"].ToString()) + "\",\"" + IDREGISTRASI + "\");^_self" + "</cell>");

                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumIdSour"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumIdLink"].ToString()) + "</cell>");

                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();
                Response.End();

                return false;

            case "SD":

                var param1SA = Request.Params["param1"].ToString();
                var param2SA = Request.Params["param2"].ToString();

                LANDCOMP.ExecuteSTP eSTP_SA = new LANDCOMP.ExecuteSTP();
                eSTP_SA.Datas();
                DataSet ds_SA = new DataSet();
                ds_SA = eSTP_SA.param7("P_PENGTO_D", param1SA, param2SA, "", "", "", "","");

                dt = ds_SA.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["pengtoNamPlk"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["pengtoLuaPlk"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["pengtoStatus"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["pengtoIdents"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["pengtoSequen"].ToString()) + "</cell>");

                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();

                Response.End();

                return false;
            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;

        }
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "L":

                HakAkses();
                var param1L = Request.Params["param1"].ToString();
                var param2L = Request.Params["param2"].ToString();
                var param4L = Request.Params["param4"].ToString();
                var param5L = Request.Params["param5"].ToString();
                LANDCOMP.ExecuteSTP eSTP_L = new LANDCOMP.ExecuteSTP();
                eSTP_L.Datas();
                DataSet ds_L = new DataSet();
                ds_L = eSTP_L.List13("P_PENLAP", param1L, param2L, "", param4L, param5L, "", "", "", "", "", groups, "", "");

                dt = ds_L.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");

                //groupsid = Session["groups"].ToString();

                for (int i = 0; i < dt.Rows.Count; i++)
                { //0
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");

                    if (groups.ToString() == "1")
                    { //1

                        Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                        Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["penlapNmrPen"].ToString()) + "</cell>");
                        Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["praregNmrPra"].ToString()) + "</cell>");
                        Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["MidentNamass"].ToString()) + "</cell>");
                        Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["praregLokdes"].ToString()) + "</cell>");
                        Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["penlapLanjut"].ToString()) + "</cell>");

                        if (dt.Rows[i]["penlapNmrPen"].ToString() != "")
                        { //2
                            Response.Write("<cell>" + RemoveWhiteSpace("View^PengecekanLapanganForm.aspx?rand=" + r.Next() + "&param1=V" + "&param2=" + dt.Rows[i]["praregNmrPra"].ToString() + "") + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace("Edit^PengecekanLapanganForm.aspx?rand=" + r.Next() + "&param1=E" + "&param2=" + dt.Rows[i]["praregNmrPra"].ToString() + "") + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace("Delete^PengecekanLapanganForm.aspx?rand=" + r.Next() + "&param1=D" + "&param2=" + dt.Rows[i]["praregNmrPra"].ToString() + "") + "</cell>");
                        } //2
                        Response.Write("</row>");
                    } //1

                    else
                    { //3

                        if (dt.Rows[i]["penlapLanjut"].ToString() != "Lanjut")
                        { //4

                            Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                            Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["penlapNmrPen"].ToString()) + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["praregNmrPra"].ToString()) + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["MidentNamass"].ToString()) + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["praregLokdes"].ToString()) + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["penlapLanjut"].ToString()) + "</cell>");

                            if (dt.Rows[i]["penlapNmrPen"].ToString() != "")
                            { //5
                                if (PengecekanLapanganView.ToString() == "1" || groups.ToString() == "1")
                                {
                                    Response.Write("<cell>" + RemoveWhiteSpace("View^PengecekanLapanganForm.aspx?rand=" + r.Next() + "&param1=V" + "&param2=" + dt.Rows[i]["praregNmrPra"].ToString() + "") + "</cell>");
                                }

                                if (PengecekanLapanganEdit.ToString() == "1" || groups.ToString() == "1")
                                {
                                    Response.Write("<cell>" + RemoveWhiteSpace("Edit^PengecekanLapanganForm.aspx?rand=" + r.Next() + "&param1=E" + "&param2=" + dt.Rows[i]["praregNmrPra"].ToString() + "") + "</cell>");
                                }

                                if (PengecekanLapanganDelete.ToString() == "1" || groups.ToString() == "1")
                                {
                                    Response.Write("<cell>" + RemoveWhiteSpace("Delete^PengecekanLapanganForm.aspx?rand=" + r.Next() + "&param1=D" + "&param2=" + dt.Rows[i]["praregNmrPra"].ToString() + "") + "</cell>");
                                }
                            } //5

                        }//4
                        Response.Write("</row>");
                    }//3

                } //0

                Response.Write("</rows>");
                dt.Dispose();

                Response.End();
                Response.End();

                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "L":

                var param1L = Request.Params["param1"].ToString();
                //var param2L = Request.Params["param2"].ToString();

                LANDCOMP.ExecuteSTP eSTP_L = new LANDCOMP.ExecuteSTP();
                eSTP_L.Datas();
                DataSet ds_L = new DataSet();
                ds_L = eSTP_L.LMID("P_MINDENT", param1L, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "");

                dt = ds_L.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");
                groupsid = Session["groups"].ToString();
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["MidentIdents"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["MidentNamass"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["MidentJnsKel"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["MidentTmplhr"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["MidentTglLhr"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["MidentStatus"].ToString()) + "</cell>");
                    if (groupsid == "Operator")
                    {
                        Response.Write("<cell>" + RemoveWhiteSpace("View^MasterIdentitasForm.aspx?rand=" + r.Next() + "&param1=F" + "&param2=" + dt.Rows[i]["MidentIdents"].ToString() + "") + "</cell>");
                    }
                    else
                    {
                        Response.Write("<cell>" + RemoveWhiteSpace("View^MasterIdentitasForm.aspx?rand=" + r.Next() + "&param1=F" + "&param2=" + dt.Rows[i]["MidentIdents"].ToString() + "") + "</cell>");
                        Response.Write("<cell>" + RemoveWhiteSpace("Edit^MasterIdentitasForm.aspx?rand=" + r.Next() + "&param1=E" + "&param2=" + dt.Rows[i]["MidentIdents"].ToString() + "") + "</cell>");
                        Response.Write("<cell>" + RemoveWhiteSpace("Delete^MasterIdentitasForm.aspx?rand=" + r.Next() + "&param1=D" + "&param2=" + dt.Rows[i]["MidentIdents"].ToString() + "") + "</cell>");
                        //Response.Write("<cell>" + RemoveWhiteSpace("Delete^javascript:Hapus(\"" + "D" + "\",\"" + "D" + "\",\"" + dt.Rows[i]["MidentIdents"].ToString() + "\",\"" + "\");^_self") + "</cell>");
                    }
                    Response.Write("</row>");
                }
                Response.Write("</rows>");

                dt.Dispose();

                Response.End();

                return false;

            //case "D":

            //    string param1D = Request.Params["param1"].ToString();
            //    string param2D = Request.Params["param2"].ToString();

            //    LANDCOMP.ExecuteSTP eSTP_D = new LANDCOMP.ExecuteSTP();
            //    eSTP_D.Datas();
            //    eSTP_D.LMID("P_MINDENT", param1D, param2D, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "");

            //    return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "V":
                var Param1 = Request.Params["param1"].ToString();
                var Param2 = Request.Params["param2"].ToString();
                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                ds = eSTP.List7("P_PERUSA", Param1, Param2, "", "", "", "", "");

                dt = ds.Tables[0];

                Response.ContentType = "text/plain";
                Response.Write(dt.Rows[0]["perusaIdents"].ToString() + "|"); //
                Response.Write(dt.Rows[0]["perusaDatess"].ToString() + "|"); //1
                Response.Write(dt.Rows[0]["perusaNamass"].ToString() + "|"); //2
                Response.Write(dt.Rows[0]["perusaKeterg"].ToString() + "|"); //3

                dt.Dispose();

                Response.End();
                Response.End();
                return false;

            //return false;

            case "CRUD":
                Response.ContentType = "text/plain";
                Response.Write(Save());
                Response.End();
                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    private String Save()
    {
        if (Session["userid"] is object)
         {
             userid = Session["userid"].ToString();

         }

         String param1 = ""; if (Request.Params["param1"] is object) param1 = Request.Params["param1"].ToString();
         String param2 = ""; if (Request.Params["param2"] is object) param2 = Request.Params["param2"].ToString();
         String param3 = ""; if (Request.Params["param3"] is object) param3 = Request.Params["param3"].ToString();
         String param4 = ""; if (Request.Params["param4"] is object) param4 = Request.Params["param4"].ToString();
         String param5 = ""; if (Request.Params["param5"] is object) param5 = Request.Params["param5"].ToString();
         String param6 = ""; if (Request.Params["param6"] is object) param6 = Request.Params["param6"].ToString();
         String param7 = ""; if (Request.Params["param7"] is object) param7 = Request.Params["param7"].ToString();
         String param8 = ""; if (Request.Params["param8"] is object) param8 = Request.Params["param8"].ToString();
         String param9 = ""; if (Request.Params["param9"] is object) param9 = Request.Params["param9"].ToString();
         String param10 = ""; if (Request.Params["param10"] is object) param10 = Request.Params["param10"].ToString();
         String param11 = ""; if (Request.Params["param11"] is object) param11 = Request.Params["param11"].ToString();
         String param12 = ""; if (Request.Params["param12"] is object) param12 = Request.Params["param12"].ToString();
         String param13 = ""; if (Request.Params["param13"] is object) param13 = Request.Params["param13"].ToString();
         String param14 = ""; if (Request.Params["param14"] is object) param14 = Request.Params["param14"].ToString();
         String param15 = ""; if (Request.Params["param15"] is object) param15 = Request.Params["param15"].ToString();
         String param16 = ""; if (Request.Params["param16"] is object) param16 = Request.Params["param16"].ToString();
         String param17 = ""; if (Request.Params["param17"] is object) param17 = Request.Params["param17"].ToString();
         String param18 = ""; if (Request.Params["param18"] is object) param18 = Request.Params["param18"].ToString();
         String param19 = ""; if (Request.Params["param19"] is object) param19 = Request.Params["param19"].ToString();
         String param20 = ""; if (Request.Params["param20"] is object) param20 = Request.Params["param20"].ToString();
         String param21 = ""; if (Request.Params["param21"] is object) param21 = Request.Params["param21"].ToString();
         String param22 = ""; if (Request.Params["param22"] is object) param22 = Request.Params["param22"].ToString();
         String param23 = ""; if (Request.Params["param23"] is object) param23 = Request.Params["param23"].ToString();
         String param24 = ""; if (Request.Params["param24"] is object) param24 = Request.Params["param24"].ToString();
         String param25 = ""; if (Request.Params["param25"] is object) param25 = Request.Params["param25"].ToString();
         String param26 = ""; if (Request.Params["param26"] is object) param26 = Request.Params["param26"].ToString();

         String sql = "";
         String output = "";

         try
         {

             output = param1;

                 if (output == "I")
                 {

                     LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                     eSTP.Datas();
                     DataSet ds = new DataSet();
                     ds = eSTP.LMID("P_MINDENT", "X", param2, param3, param4, param5, param6, param7, param8, param9, param10, param11, param12, param13, param14, param15, param16, param17, param18, param19, param20, param21, param22, param23, param24, userid, param26);
                     dt = ds.Tables[0];

                         if (dt.Rows.Count > 0)
                         {
                             if (output == "I")
                                 output = "notambah";

                             return output;
                         }
                 }

             if (output == "I" || output == "E" || output == "D")
             //if (output == "E" || output == "D")
             {

                 LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                 eSTP.Datas();
                 DataSet ds = new DataSet();
                 eSTP.save26("P_MINDENT", param1, param2, param3, param4, param5, param6, param7, param8, param9, param10, param11, param12, param13, param14, param15, param16, param17, param18, param19, param20, param21, param22, param23, param24, userid, param26);

                 return output;
             }

             //if (output == "I")
             //{

             //    LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
             //    eSTP.Datas();
             //    DataSet ds = new DataSet();
             //    eSTP.save26("P_MINDENT", "E", param2, param3, param4, param5, param6, param7, param8, param9, param10, param11, param12, param13, param14, param15, param16, param17, param18, param19, param20, param21, param22, param23, param24, param25, param26);

             //    return output;
             //}

             else
                 output = "gagal";
         }

         catch (Exception ex)
         {
             Response.Write(ex.Message);
             Response.End();
             return ex.Message;
         }

         return output;
    }
Example #26
0
    private String Save()
    {
        if (Session["userid"] is object)
        {
            userid = Session["userid"].ToString();

        }

        String param1 = ""; if (Request.Params["param1"] is object) param1 = Request.Params["param1"].ToString();
        String param2 = ""; if (Request.Params["param2"] is object) param2 = Request.Params["param2"].ToString();
        String param3 = ""; if (Request.Params["param3"] is object) param3 = Request.Params["param3"].ToString();
        String param4 = ""; if (Request.Params["param4"] is object) param4 = Request.Params["param4"].ToString();
        String param5 = ""; if (Request.Params["param5"] is object) param5 = Request.Params["param5"].ToString();
        String param6 = ""; if (Request.Params["param6"] is object) param6 = Request.Params["param6"].ToString();
        String param7 = ""; if (Request.Params["param7"] is object) param7 = Request.Params["param7"].ToString();
        String param8 = ""; if (Request.Params["param8"] is object) param8 = Request.Params["param8"].ToString();
        String param9 = ""; if (Request.Params["param9"] is object) param9 = Request.Params["param9"].ToString();
        String param10 = ""; if (Request.Params["param10"] is object) param10 = Request.Params["param10"].ToString();
        String param11 = ""; if (Request.Params["param11"] is object) param11 = Request.Params["param11"].ToString();
        String sql = "";
        String output = "";

        try
        {
            output = param1;

            if (output == "E" || output == "D" || output == "A")
            {
                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                ds = eSTP.List11("P_VISUMS", "X", param2, "", "", "", "", "", "", "", "", "");
                dt = ds.Tables[0];

                if (dt.Rows.Count > 0)
                {
                    if (output == "E")
                        output = "noedit";

                    if (output == "D")
                        output = "nodelete";

                    if (output == "A")
                        output = "noadd";

                    return output;
                }
            }

            if (output == "I" ||  output == "E" || output == "D")
            {

                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                eSTP.save11("P_VISUMS", param1, param2, param3, param4, param5, param6, param7, param8, userid, param10, param11);

                return output;
            }
            else
                output = "gagal";
        }
        catch (Exception ex)
        {
            Response.Write(ex.Message);
            Response.End();
            return ex.Message;
        }

        return output;
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {

            case "select":

                var param1SM = Request.Params["param1"].ToString();
                var param2SM = Request.Params["param2"].ToString();

                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                ds = eSTP.param26("P_MINDENT", param1SM, param2SM, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "");

                dt = ds.Tables[0];

                Response.ContentType = "text/plain";

                Response.Write(dt.Rows[0]["MidentIdents"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentJnsIdn"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentNamass"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentJnsKel"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentTmplhr"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentTgllhr"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentPekerj"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentNmrPeg"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentAlamat"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentNmrHps"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentStatus"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentNmPsng"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentTmpPas"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentTglPas"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentThnNkh"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentNmAyah"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentTglAyh"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentKrjAyh"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentAlmAyh"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentNmIbus"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentTglIbu"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentKrjIbu"].ToString() + "|");
                Response.Write(dt.Rows[0]["MidentAlmIbu"].ToString() + "|");

                dt.Dispose();

                Response.End();
                Response.End();

                return false;

            case "SA":

                var param1SA = Request.Params["param1"].ToString();
                var param2SA = Request.Params["param2"].ToString();

                LANDCOMP.ExecuteSTP eSTP_SA = new LANDCOMP.ExecuteSTP();
                eSTP_SA.Datas();
                DataSet ds_SA = new DataSet();
                ds_SA = eSTP_SA.param7("P_MINDENT_A", param1SA, param2SA, "", "", "", "", "");

                dt = ds_SA.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["midentNamass"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["midentTgllhr"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["midentPkrjan"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["midentAlamat"].ToString()) + "</cell>");
                    //Response.Write("<cell>" + RemoveWhiteSpace("View^javascript:View(\"" + "SA" + "\",\"" + "SA" + "\",\"" + dt.Rows[i]["MidentIdents"].ToString() + "\",\"" + dt.Rows[i]["midentSequen"].ToString() + "\");^_self") + "</cell>");
                    //Response.Write("<cell>" + RemoveWhiteSpace("Edit^javascript:EditDetil(\"" + "UA" + "\",\"" + "UA" + "\",\"" + dt.Rows[i]["MidentIdents"].ToString() + "\",\"" + dt.Rows[i]["midentSequen"].ToString() + "\");^_self") + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace("Delete^javascript:Hapus(\"" +"DA" + "\",\"" + "DA" + "\",\"" + dt.Rows[i]["MidentIdents"].ToString() + "\",\"" + dt.Rows[i]["midentSequen"].ToString() + "\");^_self") + "</cell>");

                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();

                Response.End();
                Response.End();

                return false;

            case "SS":

                var param1SS = Request.Params["param1"].ToString();
                var param2SS = Request.Params["param2"].ToString();

                LANDCOMP.ExecuteSTP eSTP_SS = new LANDCOMP.ExecuteSTP();
                eSTP_SS.Datas();
                DataSet ds_SS = new DataSet();
                ds_SA = eSTP_SS.param7("P_MINDENT_S", param1SS, param2SS, "", "", "", "", "");

                dt = ds_SA.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["midentNamass"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["midentTgllhr"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["midentPkrjan"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["midentAlamat"].ToString()) + "</cell>");
                    //Response.Write("<cell>" + RemoveWhiteSpace("View^javascript:View(\"" + "SS" + "\",\"" + "SS" + "\",\"" + dt.Rows[i]["MidentIdents"].ToString() + "\",\"" + dt.Rows[i]["midentSequen"].ToString() + "\");^_self") + "</cell>");
                    //Response.Write("<cell>" + RemoveWhiteSpace("Edit^javascript:Edit(\"" + "US" + "\",\"" + "US" + "\",\"" + dt.Rows[i]["MidentIdents"].ToString() + "\",\"" + dt.Rows[i]["midentSequen"].ToString() + "\");^_self") + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace("Delete^javascript:Hapus(\"" + "DS" + "\",\"" + "DS" + "\",\"" + dt.Rows[i]["MidentIdents"].ToString() + "\",\"" + dt.Rows[i]["midentSequen"].ToString() + "\");^_self") + "</cell>");

                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();

                Response.End();
                Response.End();

                return false;

            case "ListUploadIdentitasLahan":

                var Param1z = Request.Params["param1"].ToString();
                var Param2z = Request.Params["IDRegistrasi"].ToString();

                String path_pic = (HttpContext.Current.Request.Url.AbsolutePath).ToLower();

                LANDCOMP.ExecuteSTP eSTPz = new LANDCOMP.ExecuteSTP();
                eSTPz.Datas();
                DataSet dsz = new DataSet();
                dsz = eSTPz.param26("P_MINDENT", Param1z, Param2z, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "");
                //dsz = eSTPz.List34("P_REGIST", Param1z, Param2z, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "");

                dt = dsz.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");

                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>");
                    //Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["codessDescs1"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumFiless"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumFiless"].ToString()) + "</cell>");

                    Response.Write("<cell>" + "Download^" + path_pic + "?sm=df&amp;namafile=" + dt.Rows[i]["hdocumIdLink"].ToString() + "&amp;filelama=" + dt.Rows[i]["hdocumFiless"].ToString() + "</cell>");
                    //Response.Write("<cell>" + "Delete^" + path_pic + "?sm=Deletepic&amp;IDSOURCE=" + dt.Rows[i]["IDSource"].ToString() + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace("Delete^javascript:DeletePic(\"" + dt.Rows[i]["hdocumIdLink"].ToString()) + "\",\"" + Param2z + "\");^_self" + "</cell>");

                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumIdSour"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumIdLink"].ToString()) + "</cell>");
                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();
                //conn.myConnectionClose();
                Response.End();
                return false;

            case "ListUploadKelengkapan":

                var Param1a = Request.Params["param1"].ToString();
                var Param2a = Request.Params["IDRegistrasi"].ToString();

                String path_pica = (HttpContext.Current.Request.Url.AbsolutePath).ToLower();

                LANDCOMP.ExecuteSTP eSTPa = new LANDCOMP.ExecuteSTP();
                eSTPa.Datas();
                DataSet dsa = new DataSet();
                dsa = eSTPa.List6("P_REGIST_D", Param1a, Param2a, "", "", "", "");

                dt = dsa.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");

                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>");
                    //Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["codessDescs1"].ToString()) + "</cell>");
                    //Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["codessDescs2"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumFiless"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumFiless"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumFiless"].ToString()) + "</cell>");

                    Response.Write("<cell>" + "Download^" + path_pica + "?sm=df&amp;namafile=" + dt.Rows[i]["hdocumIdLink"].ToString() + "&amp;filelama=" + dt.Rows[i]["hdocumFiless"].ToString() + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace("Delete^javascript:DeletePic(\"" + dt.Rows[i]["hdocumIdLink"].ToString()) + "\",\"" + Param2a + "\");^_self" + "</cell>");

                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumIdSour"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["hdocumIdLink"].ToString()) + "</cell>");
                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();
                //conn.myConnectionClose();
                Response.End();
                return false;

            case "df":
                Response.Clear();
                string namafile = (Request.Params["filelama"] is object ? Request.Params["filelama"].ToString() : "");
                String urlfile = (Request.Params["namafile"] is object ? Request.Params["namafile"].ToString() : "");
                String randomfile = (Request.Params["random"] is object ? Request.Params["random"].ToString() : "");
                string type = "";
                switch (namafile.Substring(namafile.Length - 4))
                {
                    case ".htm":
                    case ".html":
                        type = "text/HTML";
                        break;

                    case ".txt":
                        type = "text/plain";
                        break;

                    case ".doc":
                    case ".docx":
                    case ".rtf":
                        type = "Application/msword";
                        break;
                    case ".xls":
                    case ".xlsx":
                        type = "Application/msexcel";
                        break;

                    case ".zip":
                    case ".rar":
                        type = "application/zip";
                        break;

                    case ".pdf":
                        type = "application/pdf";
                        break;
                    case ".jpg":
                        type = "image/JPG";
                        break;
                    case ".pgn":
                        type = "image/PNG";
                        break;
                    case ".tif":
                        type = "image/tif";
                        break;
                }

                Response.AddHeader("content-disposition", "attachment;filename=" + namafile + "");
                Response.ContentType = type;

                Response.WriteFile(Server.MapPath(@"~/uploaddocument/" + Request.Params["namafile"].ToString().Replace("&amp;", "&")));

                Response.End();
                return false;

            case "SaveUploadRegistrasi":
                Response.ContentType = "text/plain";
                Response.Write(SaveUploadRegistrasi());
                Response.End();
                return false;

            case "IA":

                string param1IA = Request.Params["param1"].ToString();
                string param2IA = Request.Params["param2"].ToString();
                //string param3IA = Request.Params["param3"].ToString();
                string param4IA = Request.Params["param4"].ToString();
                string param5IA = Request.Params["param5"].ToString();
                string param6IA = Request.Params["param6"].ToString();
                string param7IA = Request.Params["param7"].ToString();

                LANDCOMP.ExecuteSTP eSTP_IA = new LANDCOMP.ExecuteSTP();
                eSTP_IA.Datas();
                eSTP_IA.save7("P_MINDENT_A", param1IA, param2IA, "", param4IA, param5IA, param6IA, param7IA);

                return false;

            case "IS":

                string param1IS = Request.Params["param1"].ToString();
                string param2IS = Request.Params["param2"].ToString();
                //string param3IS = Request.Params["param3"].ToString();
                string param4IS = Request.Params["param4"].ToString();
                string param5IS = Request.Params["param5"].ToString();
                string param6IS = Request.Params["param6"].ToString();
                string param7IS = Request.Params["param7"].ToString();

                LANDCOMP.ExecuteSTP eSTP_IS = new LANDCOMP.ExecuteSTP();
                eSTP_IS.Datas();
                eSTP_IS.save7("P_MINDENT_S", param1IS, param2IS, "", param4IS, param5IS, param6IS, param7IS);

                return false;

            case "DA":

                string param1DA = Request.Params["param1"].ToString();
                string param2DA = Request.Params["param2"].ToString();
                string param3DA = Request.Params["param3"].ToString();

                LANDCOMP.ExecuteSTP eSTP_DA = new LANDCOMP.ExecuteSTP();
                eSTP_DA.Datas();
                eSTP_DA.save7("P_MINDENT_A", param1DA, param2DA, param3DA, "", "", "", "");

                return false;

            case "DS":

                string param1DS = Request.Params["param1"].ToString();
                string param2DS = Request.Params["param2"].ToString();
                string param3DS = Request.Params["param3"].ToString();

                LANDCOMP.ExecuteSTP eSTP_DS = new LANDCOMP.ExecuteSTP();
                eSTP_DS.Datas();
                eSTP_DS.save7("P_MINDENT_S", param1DS, param2DS, param3DS, "", "", "", "");

                return false;

            case "Save":
                Response.ContentType = "text/plain";
                Response.Write(Save());
                Response.End();
                return false;

            case "Insert":
                Response.ContentType = "text/plain";
                Response.Write(Save());
                Response.End();
                return false;

            case "Delete":
                Response.ContentType = "text/plain";
                Response.Write(Save());
                Response.End();
                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "V":

                var Param1 = Request.Params["param1"].ToString();
                var Param2 = Request.Params["param2"].ToString();

                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                ds = eSTP.List23("P_PMBYRN", Param1, Param2, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "");

                dt = ds.Tables[0];

                Response.ContentType = "text/plain";
                Response.Write(dt.Rows[0]["pmbyrnNmrByr"].ToString() + "|"); //0
                Response.Write(dt.Rows[0]["registNmrReg"].ToString() + "|");//1
                Response.Write(dt.Rows[0]["pmbyrnNmrPid"].ToString() + "|");//2
                Response.Write(dt.Rows[0]["pmbyrnNmrNeg"].ToString() + "|");//3
                Response.Write(dt.Rows[0]["pmbyrnNovism"].ToString() + "|");//4
                Response.Write(dt.Rows[0]["berks1NmrBr1"].ToString() + "|");//5
                Response.Write(dt.Rows[0]["pmbyrnTglASH"].ToString() + "|");//6
                Response.Write(dt.Rows[0]["pmbyrnTglAMn"].ToString() + "|");//7
                Response.Write(dt.Rows[0]["pmbyrnTglSrv"].ToString() + "|");//8
                Response.Write(dt.Rows[0]["pmbyrnTglAGm"].ToString() + "|");//9
                Response.Write(dt.Rows[0]["pmbyrnTgABod"].ToString() + "|");//10
                Response.Write(dt.Rows[0]["pmbyrnTglAcc"].ToString() + "|");//11
                Response.Write(dt.Rows[0]["pmbyrnPengBer"].ToString() + "|");//12
                Response.Write(dt.Rows[0]["pmbyrnKetrgn"].ToString() + "|");//13
                Response.Write(dt.Rows[0]["pmbyrnLnjuts"].ToString() + "|");//14
                Response.Write(dt.Rows[0]["pmbyrnEkseps"].ToString() + "|");//15
                Response.Write(dt.Rows[0]["pmbyrnKeteks"].ToString() + "|");//16
                Response.Write(dt.Rows[0]["pmbyrnNamPer"].ToString() + "|");//17
                Response.Write(dt.Rows[0]["tawar"].ToString() + "|");//18

                //Response.Write(dt.Rows[0]["pmbyrnKeteks"].ToString() + "|");

                dt.Dispose();

                Response.End();
                Response.End();
                return false;

            case "CRUD":
                Response.ContentType = "text/plain";
                Response.Write(Save());
                Response.End();
                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {
            case "L":

                HakAkses();
                var param1L = Request.Params["param1"].ToString();
                var param2L = Request.Params["param2"].ToString();
                var param4L = Request.Params["param4"].ToString();
                var param5L = Request.Params["param5"].ToString();
                LANDCOMP.ExecuteSTP eSTP_L = new LANDCOMP.ExecuteSTP();
                eSTP_L.Datas();
                DataSet ds_L = new DataSet();
                ds_L = eSTP_L.List14("P_BERKS1", param1L, param2L, "", param4L, param5L, "", "", "", "", "", "", "", "", "");

                dt = ds_L.Tables[0];
                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");

                //groupsid = Session["groups"].ToString();

                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["berks1NmrBr1"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["negosiNmrReg"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["pengtoNmrPid"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["berks1Assign"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["MidentNamass"].ToString()) + "</cell>");
                    if (dt.Rows[i]["berks1NmrBr1"].ToString() != "")
                    {
                        if (groups.ToString() == "1")
                        {
                            Response.Write("<cell>" + RemoveWhiteSpace("View^PemberkasanSatuForm.aspx?rand=" + r.Next() + "&param1=V" + "&param2=" + dt.Rows[i]["visumsNovism"].ToString() + "") + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace("Edit^PemberkasanSatuForm.aspx?rand=" + r.Next() + "&param1=E" + "&param2=" + dt.Rows[i]["visumsNovism"].ToString() + "") + "</cell>");
                            Response.Write("<cell>" + RemoveWhiteSpace("Delete^PemberkasanSatuForm.aspx?rand=" + r.Next() + "&param1=D" + "&param2=" + dt.Rows[i]["visumsNovism"].ToString() + "") + "</cell>");
                        }
                        else
                        {
                            //if (dt.Rows[i]["berks1Assign"].ToString() != "Lanjut")
                            //{
                                if (PemberkasanView.ToString() == "1")
                                {
                                    Response.Write("<cell>" + RemoveWhiteSpace("View^PemberkasanSatuForm.aspx?rand=" + r.Next() + "&param1=V" + "&param2=" + dt.Rows[i]["visumsNovism"].ToString() + "") + "</cell>");
                                }
                                if (PemberkasanEdit.ToString() == "1")
                                {
                                    Response.Write("<cell>" + RemoveWhiteSpace("Edit^PemberkasanSatuForm.aspx?rand=" + r.Next() + "&param1=E" + "&param2=" + dt.Rows[i]["visumsNovism"].ToString() + "") + "</cell>");
                                }
                                if (PemberkasanDelete.ToString() == "1")
                                {
                                    Response.Write("<cell>" + RemoveWhiteSpace("Delete^PemberkasanSatuForm.aspx?rand=" + r.Next() + "&param1=D" + "&param2=" + dt.Rows[i]["visumsNovism"].ToString() + "") + "</cell>");

                                }
                            //}
                        }

                    }

                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();

                Response.End();
                Response.End();

                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }
    private bool ServiceSelect(string sm)
    {
        switch (sm)
        {

            case "E":

                Response.ContentType = "text/plain";
                var param1 = Request.Params["param1"].ToString();
                var param2 = Request.Params["param2"].ToString();
                var param4 = Request.Params["param4"].ToString();
                var param5 = Request.Params["param5"].ToString();
                var param19 = Request.Params["param19"].ToString();
                var param20 = Request.Params["param20"].ToString();
                //var param17 = "hanny"; //session
                var param17 = Session["userid"].ToString();
                LANDCOMP.ExecuteSTP eSTP = new LANDCOMP.ExecuteSTP();
                eSTP.Datas();
                DataSet ds = new DataSet();
                eSTP.save22("P_PENGTO", param1, param2, "", param4, param5, "", "", "", "", "", "", "", "", "", "", "", param17, "", param19, param20, "", "");
                    Response.End();
                    return false;

            case "L":

                var param1L = Request.Params["param1"].ToString();
                var param2L = Request.Params["param2"].ToString();
                var param4L = Request.Params["param4"].ToString();
                var param5L = Request.Params["param5"].ToString();
                LANDCOMP.ExecuteSTP eSTP_L = new LANDCOMP.ExecuteSTP();
                eSTP_L.Datas();
                DataSet ds_L = new DataSet();
                ds_L = eSTP_L.List22("P_PENGTO", param1L, param2L, "", param4L, param5L, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "");

                dt = ds_L.Tables[0];

                Response.ContentType = "application/xhtml+xml";
                Response.Write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
                Response.Write("<rows>");
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    Random r = new Random();
                    Response.Write("<row id=\"" + (i + 1).ToString() + "\">");
                    Response.Write("<cell>" + (i + 1).ToString() + "</cell>"); // Untuk Membuat Angka
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["PENGTO"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["registNmrReg"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["MidentNamass"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["praregLokkec"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["praregLokdes"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["pengtoAssign"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["Assign"].ToString()) + "</cell>");
                    Response.Write("<cell>" + RemoveWhiteSpace(dt.Rows[i]["pengtoIdents"].ToString()) + "</cell>");
                    Response.Write("</row>");
                }
                Response.Write("</rows>");
                dt.Dispose();

                Response.End();
                Response.End();

                return false;

            default:
                Response.ContentType = "text/plain";
                Response.End();
                return true;
        }
    }