Path: utzoo!attcan!uunet!jarthur!usc!cs.utexas.edu!asuvax!enuxha!rao From: rao@enuxha.eas.asu.edu (Arun Rao) Newsgroups: comp.windows.x Subject: Trouble with setting label in dialog widget Message-ID: <495@enuxha.eas.asu.edu> Date: 12 Feb 90 16:26:02 GMT Distribution: na Organization: Arizona State Univ, Tempe Lines: 46 I have a popup shell in my application which contains a dialog widget. The label of this dialog widget is set (using XtSetValues) just before popping it up in a callback routine, and the string displayed varies. The trouble is that the XtSetValues() is completely ignored after the first call - the label is set once, and does not change, even though I've checked that the string I'm using is actually different. The code fragment is given below: void callback(w, client_data, call_data) .................... { .................. if(n_vector != 0) sprintf(buffer,"Nearest match is %s, \n%f units away\0", best_match, min_dist); else sprintf(buffer, "Database is empty"); n = 0; XtSetArg(wargs[n], XtNlabel, buffer); n++; XtSetArg(wargs[n], XtNsensitive, TRUE); n++; XtSetValues(client_data->dialog1, wargs, n); XtPopup(client_data->popup_shell1, XtGrabExclusive); .................. } Any help is greatly appreciated. Thanks in advance. -Arun -- Arun Rao INTERNET: rao@enuxha.eas.asu.edu,rao@acvax.inre.asu.edu BITNET: agaxr@asuacvax 950 S. Terrace Road, #B324, Tempe, AZ 85281 Phone: (602) 968-1852 (Home) (602) 965-3452 (Office)