I want the operator to know if they input a duplicate job number by showing a popup. I am able to make the popup work, but for some reason, I can’t change the size of the popup at all.
Button script:
jobNumInput = self.getSibling("JobNumInput").props.text
try:
result = system.db.runNamedQuery( "Arms/ProductionData", {"jobNumInput":jobNumInput})
if result.rowCount == 1:
message = "✅ Job number inserted successfully."
else:
message = "⚠️ Job number already exists. No insert performed."
except Exception as e:
message = "❌ Error inserting job number: " + str(e)
# Open the popup with the message
system.perspective.openPopup(
id="jobInsertFeedback",
view="JobInsertFeedbackPopup",
params={"message": message},
title="Insert Status",
modal=True,
showCloseIcon=True,
resizeable = True,
)
# Table Refresh
messageType = 'Refresh Table'
system.perspective.sendMessage(messageType)
Here is the popup: