About the auto complete feature

So many things to say, so few words to use and English is not my mother tongue !

I try to be short and concise and I will use TextInputStream for demonstration.

Auto complete is a real good help, and now it is ‘context sensitive’.

In other words, you will get different entries depending on what is before the TextInputStream occurence (reference, whatever):

[code]Dim t As TextInputStream

t.… will display:
Close
Constructor
Encoding
LastErrorCode
Open
PositionB[/code]

[code]Dim t As TextInputStream

While Not t.… will display:
Encoding
EOF
Handle
HandleTypeFileNumber = 3
HandlrTypeFilePointer : 2
HandleFileTypeWin32Handle = 1
LastErrorCode
Open
PositionB
Read
ReadAll
ReadError
ReadLine
[/code]
Doing so (but after reading the example there: http://documentation.xojo.com/index.php/TextInputStream [search While Not textInput.EOF]) I discovered (back) EOF.

I searched about EOF description (I do not found it in the Property description) and had hard times 'till - with the LOCAL docs - I copy / Paste the whole page from Xojo’s Help into a TextEdit page and I searched from there to find it.

This leads into a great waste of time and I do not talk about the time to write this text.

What’s your opinion?

I think you should file a feedback report against the documentation. EOF should be listed as a property (it’s really a method) with the other properties/methods.

The image below is what you will get if you typed While Not t.:

And this image is what you will get if you type t.:

This is the first time I am able to pass an image to this forum. I have to thank the person who gave me the tip some times ago. Tip I forgot, but a search allows me to get it bacl.

I could be wrong, but I think when you type t.… you are seeing things that can be called/set
while not t.… lists items that can be compared to false… number values, methods that return numbers or booleans.

Jim,

you have above the screen shot of what you have when you type t.… alone in a line and with “While Not t.…” in a line.

I do not checked other solutions. I checked while not because I saw it in an example AND I do not saw EOF on t.…

Now, I may have misunderstand your anwser. If so, please explain.

I’m basically just saying , to write

t.EOF 

is not valid, so is not shown to autocomplete

while not t.EOF

is a valid completion and is shown.

You can also write

Call t.

and EOF is in the list
Or maybe I misunderstood the original question…

Jim’s exactly right

It’s correct in both cases

It’s smart enough to know if you have tried to assign or test a value (so it SHOULD show you things that can return values OR properties) or NOT

It doesn’t show you things that make no syntactic sense given what you have written so far

We could make it show you everything all the time but it’s a lot less helpful

OK Jim, I do not understand the first time.

Norman, you also are right, but if you do not saw EOF in the list of properties in the TextInputStream definition page, how can you know EOF exists ?

That is the point I wanted to highlight:
I do not saw it (EOF) in the TextInputStream definition page,
It is not shown with Auto Complete,
It does not exists.

And, because I was watching carefully one of the examples, I saw it and started to investigate… and found it.

It may be a good idea to mathe some arrangements to the docs page for people like me or worst…

This can be done (how ?) in the docs, but maybe also in the Auto Complete rect: contextually available entries are drawn standard, nit available here BUT existsing entries can (?) be in Red (as an example, if it is possible). Read means it exists, but it cannot be used here (no syntactic sense here)

Actually I would find that far more helpful. I’m always forgetting the name of a property or method and typing class. to see the list. I’ve often wondered why it didn’t always show everything, now I know.

Ian,

I just discover that…

And yes, Norman does it the good way, but there is a miss somewhere (check my previous note).

I wasn’t asking for it to change, I’m just too lazy to check the documentation. :slight_smile:

Oh ! I’m too lazy to think, so I read the documentation.

Happy Xmas.

Its listed on that page under “Interfaces”

It might help you remember but it’d be somewhat less helpful as it would suggest things that make no syntactic sense

You be wondering why it suggested

 t.EOF =

which would be completely bogus. You could ask for it via a feature request but I have my doubts we’d do it.

As I said, I wasn’t asking to change anything.

I have updated the TextInputStream page to show EOF and the other interface methods in the Methods section.