public static object Get_sPresetMaterial(int materialType = 0) { string typicalName = "Typical Steel" + "\nSteel A992 Fy50"; eMaterialType matType = eMaterialType.STEEL_A992_Fy50; if (materialType == 0) { matType = eMaterialType.STEEL_A992_Fy50; typicalName = "Typical Steel" + "\nSteel A992 Fy50"; } else if (materialType == 1) { matType = eMaterialType.ALUMINUM_6061_T6; typicalName = "Typical Aluminum" + "\nAluminum 6061 T6"; } else if (materialType == 2) { matType = eMaterialType.CONCRETE_FC3000_NORMALWEIGHT; typicalName = "Typical Concrete" + "\nConcrete FC3000 NormalWeight"; } else if (materialType == 3) { matType = eMaterialType.OAK_TYP; typicalName = "Typical OAK"; } else if (materialType == 4) { matType = eMaterialType.CARBONFRP_TYP; typicalName = "Typical CarbonFRP"; } else if (materialType == 5) { matType = eMaterialType.STAINLESSSTEEL_TYP; typicalName = "Typical StainlessSteel"; } else if (materialType == 6) { matType = eMaterialType.STEEL_A36; typicalName = matType.ToString(); } else if (materialType == 7) { matType = eMaterialType.STEEL_A53GrB; typicalName = matType.ToString(); } else if (materialType == 8) { matType = eMaterialType.STEEL_A500GrB_Fy42; typicalName = matType.ToString(); } else if (materialType == 9) { matType = eMaterialType.STEEL_A500GrB_Fy46; typicalName = matType.ToString(); } else if (materialType == 10) { matType = eMaterialType.STEEL_A572Gr50; typicalName = matType.ToString(); } else if (materialType == 11) { matType = eMaterialType.STEEL_A913Gr50; typicalName = matType.ToString(); } else if (materialType == 12) { matType = eMaterialType.STEEL_A992_Fy50; typicalName = matType.ToString(); } else if (materialType == 13) { matType = eMaterialType.CONCRETE_FC3000_NORMALWEIGHT; typicalName = matType.ToString(); } else if (materialType == 14) { matType = eMaterialType.CONCRETE_FC4000_NORMALWEIGHT; typicalName = matType.ToString(); } else if (materialType == 15) { matType = eMaterialType.CONCRETE_FC5000_NORMALWEIGHT; typicalName = matType.ToString(); } else if (materialType == 16) { matType = eMaterialType.CONCRETE_FC6000_NORMALWEIGHT; typicalName = matType.ToString(); } else if (materialType == 17) { matType = eMaterialType.CONCRETE_FC3000_LIGHTWEIGHT; typicalName = matType.ToString(); } else if (materialType == 18) { matType = eMaterialType.CONCRETE_FC4000_LIGHTWEIGHT; typicalName = matType.ToString(); } else if (materialType == 19) { matType = eMaterialType.CONCRETE_FC5000_LIGHTWEIGHT; typicalName = matType.ToString(); } else if (materialType == 20) { matType = eMaterialType.CONCRETE_FC6000_LIGHTWEIGHT; typicalName = matType.ToString(); } else if (materialType == 21) { matType = eMaterialType.ALUMINUM_6061_T6; typicalName = matType.ToString(); } else if (materialType == 22) { matType = eMaterialType.ALUMINUM_6063_T6; typicalName = matType.ToString(); } else if (materialType == 23) { matType = eMaterialType.ALUMINUM_5052_H34; typicalName = matType.ToString(); } else if (materialType == 24) { matType = eMaterialType.COLDFORMED_Grade_33; typicalName = matType.ToString(); } else if (materialType == 25) { matType = eMaterialType.COLDFORMED_Grade_50; typicalName = matType.ToString(); } sMaterial mat = new sMaterial(typicalName, matType); string mss = typicalName; if (matType == eMaterialType.OAK_TYP) { mss += "\nUse in Extra Cautious"; } //add more... return(new Dictionary <string, object> { { "materialName", mss }, { "sMaterial", mat } }); }
private void menuChangeMode(object sender, EventArgs e) { var dataIn = sender.ToString(); if (dataIn == "Steel(Typical)") { matType = eMaterialType.STEEL_A992_Fy50; typicalName = "Typical Steel" + "\nSteel A992 Fy50"; } else if (dataIn == "Aluminum(Typical)") { matType = eMaterialType.ALUMINUM_6061_T6; typicalName = "Typical Aluminum" + "\nAluminum 6061 T6"; } else if (dataIn == "Concrete(Typical)") { matType = eMaterialType.CONCRETE_FC3000_NORMALWEIGHT; typicalName = "Typical Concrete" + "\nConcrete FC3000 NormalWeight"; } else if (dataIn == "OAK(Typical)") { matType = eMaterialType.OAK_TYP; typicalName = "Typical OAK"; } else if (dataIn == "CarbonFRP(Typical)") { matType = eMaterialType.CARBONFRP_TYP; typicalName = "Typical CarbonFRP"; } else if (dataIn == "StainlessSteel(Typical)") { matType = eMaterialType.STAINLESSSTEEL_TYP; typicalName = "Typical StainlessSteel"; } else if (dataIn == "STEEL_A36") { matType = eMaterialType.STEEL_A36; typicalName = matType.ToString(); } else if (dataIn == "STEEL_A53GrB") { matType = eMaterialType.STEEL_A53GrB; typicalName = matType.ToString(); } else if (dataIn == "STEEL_A500GrB_Fy42") { matType = eMaterialType.STEEL_A500GrB_Fy42; typicalName = matType.ToString(); } else if (dataIn == "STEEL_A500GrB_Fy46") { matType = eMaterialType.STEEL_A500GrB_Fy46; typicalName = matType.ToString(); } else if (dataIn == "STEEL_A572Gr50") { matType = eMaterialType.STEEL_A572Gr50; typicalName = matType.ToString(); } else if (dataIn == "STEEL_A913Gr50") { matType = eMaterialType.STEEL_A913Gr50; typicalName = matType.ToString(); } else if (dataIn == "STEEL_A992_Fy50") { matType = eMaterialType.STEEL_A992_Fy50; typicalName = matType.ToString(); } else if (dataIn == "CONCRETE_FC3000_NORMALWEIGHT") { matType = eMaterialType.CONCRETE_FC3000_NORMALWEIGHT; typicalName = matType.ToString(); } else if (dataIn == "CONCRETE_FC4000_NORMALWEIGHT") { matType = eMaterialType.CONCRETE_FC4000_NORMALWEIGHT; typicalName = matType.ToString(); } else if (dataIn == "CONCRETE_FC5000_NORMALWEIGHT") { matType = eMaterialType.CONCRETE_FC5000_NORMALWEIGHT; typicalName = matType.ToString(); } else if (dataIn == "CONCRETE_FC6000_NORMALWEIGHT") { matType = eMaterialType.CONCRETE_FC6000_NORMALWEIGHT; typicalName = matType.ToString(); } else if (dataIn == "CONCRETE_FC3000_LIGHTWEIGHT") { matType = eMaterialType.CONCRETE_FC3000_LIGHTWEIGHT; typicalName = matType.ToString(); } else if (dataIn == "CONCRETE_FC4000_LIGHTWEIGHT") { matType = eMaterialType.CONCRETE_FC4000_LIGHTWEIGHT; typicalName = matType.ToString(); } else if (dataIn == "CONCRETE_FC5000_LIGHTWEIGHT") { matType = eMaterialType.CONCRETE_FC5000_LIGHTWEIGHT; typicalName = matType.ToString(); } else if (dataIn == "CONCRETE_FC6000_LIGHTWEIGHT") { matType = eMaterialType.CONCRETE_FC6000_LIGHTWEIGHT; typicalName = matType.ToString(); } else if (dataIn == "ALUMINUM_6061_T6") { matType = eMaterialType.ALUMINUM_6061_T6; typicalName = matType.ToString(); } else if (dataIn == "ALUMINUM_6063_T6") { matType = eMaterialType.ALUMINUM_6063_T6; typicalName = matType.ToString(); } else if (dataIn == "ALUMINUM_5052_H34") { matType = eMaterialType.ALUMINUM_5052_H34; typicalName = matType.ToString(); } else if (dataIn == "COLDFORMED_Grade_33") { matType = eMaterialType.COLDFORMED_Grade_33; typicalName = matType.ToString(); } else if (dataIn == "COLDFORMED_Grade_50") { matType = eMaterialType.COLDFORMED_Grade_50; typicalName = matType.ToString(); } RecordUndoEvent("Constant changed"); this.ExpireSolution(true); }