RE: NEWERA - multiple windows
Posted in 1997
Topics: Connectivity: ESQL/C, 4GL & Embedded SQL, Internationalization & Character Sets
Mike Ripley wrote: > WINA is my start window. From it I can call WIN1 to WIN9 so I include > the ".4gh" of all these windows in WINA. But WIN7 may want to call WIN3 > directly so I include "WIN3.4gh" in WIN7. Should I include all my ".4gh" > in all my programs to cover every eventuality or is there a simpler > way?. The way I do it is to create a calling (or entry) function for each window within each source wif file as necessary: WINA would have an open_WINA() or appropriate function within WINA.wif WIN1 ... open_WIN1() within WIN1.wif WIN2 ... open_WIN2()... ..and so on. This way, I call the function and I don't have to have to worry about adding a lot of include 4gh files along the way. This helps to keep the code more modularized and I also give the compiler a rest from a large ALL_4GLS file with the larger projects. This is also a great way to pass parameters to the opening windows (if necessary), thus avoiding too many globals and/or globals definition files within a system... My .02 worth. Hope it helps out! btt