OPEN DATA FILE gets endless loop

2019-10-27 Thread wangel--- via 4D_Tech
I am trying to use in "On Startup" but I get an endless loop. The code is: C_TEXT($dataPath) $dataPath:="C:\\MyFolder\\MyData.4dd" If ($dataPath#"") OPEN DATA FILE($dataPath) //open it $dataPath:="" End if What am I doing wrong? Regards Carl Aage Wangel

Re: OPEN DATA FILE gets endless loop

2019-10-27 Thread Jeremy Roussak via 4D_Tech
Carl, I hesitate to suggest something quite so obvious, but it seems to me that each time you enter the On Startup method, you 1. Set $dataPath to a path 2. Test $dataPath is “”, which of course it isn’t 3. Open a data file 4. Set $dataPath to “” (effectively pointless) 5. Re-enter On startup