Ejemplo n.º 1
0
    private String SaveUploadKelengkapan()
    {
        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 param3  = Request.Params["param3"].ToString();
        string param4  = Request.Params["param4"].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.save6("P_REGIST_D", param1, IDRegistrasi, param3, param4, _stKeterangan, "");

        if (param3 == "1")
        {
            param3 = "10";
        }
        if (param3 == "2")
        {
            param3 = "11";
        }
        if (param3 == "3")
        {
            param3 = "12";
        }
        if (param3 == "4")
        {
            param3 = "13";
        }

        if (extension != ".exe")
        {
            uf.UploadFilesWeb("I", user, _stDates, "Registrasi", param3, uploadFolder, IDRegistrasi, _stNomor + extension, _stNamaFile, param4);
        }

        var _stOutput = IDRegistrasi;

        return(_stOutput);
    }
Ejemplo n.º 2
0
    public void AjaxFileUploadKelengkapan_UploadComplete(object sender, AjaxControlToolkit.AjaxFileUploadEventArgs e)
    {
        if (Session["userid"] is object)
        {
            userid = Session["userid"].ToString();
        }

        //string user = "";
        string wilayah = "";

        LANDCOMP.generateNUm gn = new LANDCOMP.generateNUm();
        gn.Datas();

        string _stNomor;

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

        string uploadFolder = Request.PhysicalApplicationPath + "uploadDocument\\";

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

        ext.setExtension(Path.GetExtension(e.FileName));

        if (ext.getExtsion() != ".exe")
        {
            _stFAsli = System.IO.Path.GetFileName(e.FileName);


            _stNomor = gn.GenerateNumber("", 101, 3, _stDates, userid);

            AjaxFileUploadKelengkapan.SaveAs(uploadFolder + _stNomor + ext.getExtsion());
            e.PostedUrl = string.Format(e.FileName + "|" + _stNomor + "|" + userid + "|" + wilayah);
        }
    }
Ejemplo n.º 3
0
    public void AjaxFileUploadMRS_UploadComplete(object sender, AjaxControlToolkit.AjaxFileUploadEventArgs e)
    {
        string user    = Request.Params["user"].ToString();
        string wilayah = Request.Params["wilay"].ToString();

        LANDCOMP.generateNUm gn = new LANDCOMP.generateNUm();
        gn.Datas();

        string _stNomor;

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

        string uploadFolder = Request.PhysicalApplicationPath + "uploadDocument\\";

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

        ext.setExtension(Path.GetExtension(e.FileName));

        if (ext.getExtsion() != ".exe")
        {
            _stFAsli = System.IO.Path.GetFileName(e.FileName);

            string wilay  = user;
            string owner1 = "";
            switch (wilayah)
            {
            case "1":
                owner1 = "SBU1";
                break;

            case "2":
                owner1 = "SBU2";
                break;

            case "3":
                owner1 = "SBU3";
                break;

            case "4":
                owner1 = "TSJ1";
                break;

            case "5":
                owner1 = "LANDCOMP1";
                break;

            default:
                break;
            }

            _stNomor = gn.GenerateNumber(owner1, 100, 51, _stDates, user);

            AjaxFileUploadMRS.SaveAs(uploadFolder + _stNomor + ext.getExtsion());
            e.PostedUrl = string.Format(e.FileName + "|" + _stNomor + "|" + user + "|" + wilayah);
        }
    }
    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);
    }