Hello,
I am trying to display a variable value in a panel. I am using the digits() function and it works for the initial value of the variable. However, as the variable changes, it's not updating in the panel. What do I have to do to get it to update? Can I redraw the panel somehow? Also, when I use TEXT and define a string and display it on the panel, when I update the value, it's not always changing on the panel either (although it is changing sometimes). I have a feeling it has something to do with wait(1)?
As you can tell, this is all new to me. Please help!
Code:
Panel briefing_pan
{
bmap = "PatientBriefingPanel.bmp";
button(680, 600, "NextOn.bmp", "NextOff.bmp", "NextOn.bmp", next2, NULL, NULL);
layer = 5;
red = 0;
green = 0;
blue = 0;
digits(433, 250, 6, arial_font, 1, age[currentPatient]);
digits(108, 285, 6, arial_font, 1, height[currentPatient]);
digits(450, 285, 6, arial_font, 1, weight[currentPatient]);
digits(604, 250,"%0.f / ",arial_font, 1,sys_month); // Month in Date
digits(632, 250,"%0.f / ",arial_font, 1,sys_day); // Day in Date
digits(662, 250, 4, arial_font, 1,sys_year); // Year in Date
digits(139, 565, 6, arial_font, 1, heart_rate[currentPatient]);
digits(392, 565, 6, arial_font, 1, O2_sat[currentPatient]);
digits(630, 565, 6, arial_font, 1, blood_pressure_top[currentPatient]);
digits(171, 601, 6, arial_font, 1, resp_rate[currentPatient]);
digits(399, 601, 6, arial_font, 1, blood_glucose[currentPatient]);
flags = overlay;
}