qt - Accessing the value in Qmap with the help of its key -


i have qmap , have defined qmap<qstring,modelvariables>modelmap modelvariables structure parameters valueref,value , id. want access parameter value defined in structure. wrote following code shows error.

float hxt_val_ft04 = modelmap.value("hxt_v_ft04"); 

error: expected primary expression before '.' token.

mvariables["hxt_v_ft04"] return modelvariables object if there key matching "hxt_v_ft04". otherwise default construct object , return it. can use

mvariables["hxt_v_ft04"].value 

Comments

Popular posts from this blog

python - No exponential form of the z-axis in matplotlib-3D-plots -

c# - "Newtonsoft.Json.JsonSerializationException unable to find constructor to use for types" error when deserializing class -

Why does a .NET 4.0 program produce a system.unauthorizedAccess error on a Windows Server 2012 machine with .NET 4.5 installed? -