home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / sys / amiga / programm / 11414 next >
Encoding:
Text File  |  1992-07-20  |  1.3 KB  |  49 lines

  1. Path: sparky!uunet!cs.utexas.edu!sun-barr!olivea!hal.com!darkstar.UCSC.EDU!cats.ucsc.edu!smythe
  2. From: smythe@cats.ucsc.edu (Brian Matthew Aljian)
  3. Newsgroups: comp.sys.amiga.programmer
  4. Subject: Need help with GadTools stuff...
  5. Message-ID: <14g6bbINN81o@darkstar.UCSC.EDU>
  6. Date: 21 Jul 92 05:12:11 GMT
  7. Organization: University of California; Santa Cruz
  8. Lines: 38
  9. NNTP-Posting-Host: am.ucsc.edu
  10.  
  11.  
  12. I'm having problems getting text to show up in Text-Entry and Text-Display
  13. gadgets.  Specifically, I'm having problems manipulating and setting the
  14. pointers that point to the text I want to put in the gadgets.  Note that
  15. I'm using the GadToolsLibrary.
  16.  
  17. I have in an include file:
  18.  
  19. STRPTR Item1;
  20. STRPTR Item2;
  21.  
  22. struct TagItem Item1_Tags[] =
  23. {
  24.     {GTST_String,        &Item1},
  25.     {TAG_DONE,        NULL},
  26. };
  27.  
  28. struct TagItem Item2_Tags[] =
  29. {
  30.     {GTTX_Text,        &Item2},
  31.     {TAG_DONE,        NULL},
  32. };
  33.  
  34. Then in main() I have...
  35.  
  36.    Item1 = "sample1";
  37.    Item2 = "sample2";
  38.  
  39. When I run my program I get garbage in the two fields.  I know I'm not doing
  40. my pointers correctly, but I've tried everything I can think of to remedy
  41. this problem.  Can someone please help me?
  42.  
  43. Thanks *VERY* much in advance for any help!  I've been stuck on this for many
  44. days now.  :-(
  45.  
  46. -- 
  47.    Brian M. Aljian
  48.    smythe@stallion.santa-cruz.ca.us
  49.