Pop up method option selector - Linking Frontend UI to Backend Functionality

I have been working on a method for my team and I would like to enhance it by adding a user interface (UI) element. The UI has options for selecting certain settings and adding files.

I have already created the HTML part of the UI, but I am unsure how to link it to the backend functionality. Specifically, I want the method to start when the user clicks the “Start” button and abort when the “Abort” button is clicked. However, I am not sure which variables or parameters need to be passed in order to make this happen.

I would appreciate any guidance or assistance you can provide in connecting the frontend UI to the backend functionality. Thank you.

1 Like

for abort, you’re probably looking for one of these:

For initiating a run, not sure. I haven’t run into anything yet that resembles that functionality, but I’m sure there’s something.

See this post. I have attached a link to download the UI. You can edit it as you wish.

Also, I have a picture named “BFXNAME” that will export the variable to Biomke.

Regarding the “Start” and “Abort” buttons, ensure the functions in the HTML code (JavaScript) are written correctly.

image

If you edit the attached UI, it should work fine for you. If not, just send me the link to your UI, and I will edit it and send it back to you

If you have a constant folder that you always choose the file from, there is another alternative I like to work with.

You can replace the “Choose File” button with a text input field. This way, the user can write only the name of the file (or scan the plate barcode if it’s the same as the file name).

Then, on Biomek, add this script:

Option Explicit
Dim FileLoc 
Dim objFSO
Set objFSO = CreateObject("Scripting.FileSystemObject") ' Initialize FileSystemObject

FileLoc = "C:\Users\Public\Documents\LF Inputs\Transfection\ExportFile\" & BRC1 & ".csv"
' The global variable is being set to the file location
If Not objFSO.FileExists(FileLoc) Then
    ' Displaying an error message and aborting the activity if the file doesn't exist
    World.Globals.PauseGenerator.btnPromptUser "Please check the Input File " & BRC1, Array("Abort"), "Abort"
    World.Globals.ErrorGenerator.AbortRun 0, "LeftPod", True ' Assuming LeftPod is a correct parameter
Else    
    World.Globals.PropertyChanger.SetGlobal "FileLoc", FileLoc
End If

Set objFSO = Nothing ' Release the object

4 Likes

could you send us the vbscript code you are using? you probably already have one since you can display the UI?

In the previous post, I have attached a download link. It contains VBScript code and HTML for the UI. You do not need to modify the VBScript code; you only need to edit the HTML and JavaScript code.

2 Likes

Would you be able to refresh the transfer link? Looks like it has expired.

Hey,
Attachment link :https://www.mediafire.com/file/8nhalqf4l8tkv3r/UI_Biomek.rar/file

Hi thank you so much for this!
Any idea where I can find this document, this would help a lot for all the scripting we have been trying to implement in our lab.

Which document are you referring to?

If you would like, please explain the process you need to complete on this UI you shared

I will then send it back to you, and you can start editing any UI/application as needed.
(Share deck )