Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

20
LINES

< > BotCompany Repo | #1026781 // Upload file to file server [authed only]

JavaX source code (Dynamic Module) [tags: use-pretranspiled] - run with: Stefan's OS

Uses 911K of libraries. Click here for Pure Java version (5793L/29K).

!7

cmodule UploadFile {
  S filePath, result;
  
  visual
    withMargin(vstackWithSpacing(
      jCenteredSection("File to upload",
        dm_filePathInput filePath()),
      jbutton("Upload", rThread upload),
      dm_fieldLabel result()));
    
  void upload enter {
    try {
      setField(result := uploadFileToFileServer(filePath));
    } catch print e {
      setField(result := exceptionToStringShort(e));
    }
  }
}

download  show line numbers  debug dex  old transpilations   

Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv

No comments. add comment

-
Snippet ID: #1026781
Snippet name: Upload file to file server [authed only]
Eternal ID of this version: #1026781/4
Text MD5: 868ee6ac078e4787bdf3025488240efa
Transpilation MD5: bc0bee09bfb67dd9be376c36b35892bb
Author: stefan
Category: javax / stefan's os
Type: JavaX source code (Dynamic Module)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2020-01-22 14:25:23
Source code size: 447 bytes / 20 lines
Pitched / IR pitched: No / No
Views / Downloads: 193 / 313
Version history: 3 change(s)
Referenced in: