Multiple conditions for calculation answer

Hi, I am new to MATLab App Designer. I'm trying to do a settlement foundation calculator but based on multiple conditions. First, user can choose either in SI unit or Conventional Unit, then they have to choose the foundation width in the radio button group since there are various formula based on its width. I have attached my code for your reference. Thank you in advanced!
% Button pushed function: CalculateButton_3
function CalculateButton_3Pushed(app, event)
depthfactor = app.DepthFactorDfEditField_3.Value;
bearingprs = app.NetBearingPressureqEditField.Value;
n60 = app.StandardPenetrationTestN60EditField.Value;
B = app.FoundationWidthBEditField.Value;
if app.ConventionalButton.Value && app.Button_2
Se= (2.5*bearingprs)/(n60*depthfactor);
app.SettlementSeEditField.Value= Se;
else app.ConventionalButton.Value && app.Button
Se= (4*bearingprs)/(n60*depthfactor);
app.SettlementSeEditField.Value= Se;
end

1 Commento

What are app.Button and app.Button_2?
Are you sure that else shouldn't be elseif?
What's your question for us?

Accedi per commentare.

Risposte (0)

Categorie

Scopri di più su Develop Apps Using App Designer in Centro assistenza e File Exchange

Richiesto:

il 3 Dic 2022

Modificato:

Jan
il 4 Dic 2022

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by