Hi All
How do I create a shared variable length string in WINFBE?
I need to create a constantly changing list of about 40 items , but I will need to be able to access that list from different functions.
I also need to create a variable length array from that list and make the array accessible to the other functions and update the array as the list changes.
A few Pointers will be most helpful.
Regards,
Peter
A shared (global) string can be created by using DIM SHARED at the top of your source file outside of any sub or function.
dim shared myString as string
You would do the same for an array:
redim shared myArray() as string
I see what i did.
I was at the right place, but i tried to add the string content there as well.
That would be a problem.
Moved that bit to a function and now it works.
Regards
Peter
No problem. I also edited my post because I think that dynamic shared arrays need to be created using "REDIM SHARED" rather than "DIM SHARED". I am not on my Windows computer right now but the FB online help seems to suggest that REDIM SHAREDis what you need to use.
Thank you so much Paul.
You cannot imagine how chuffed I am over this little predictive text function that now works like a charm.
This forum and its members are just remarkable.
Regards,
Peter