How to adress a field wich is on another field
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
How to adress a field wich is on another field
Hello,
I have put a field (aField) on an scrolling field (SField)
How can i put text into that field (with the name afield)?
put "xxx" into aField creates an error no such chunk
I have put a field (aField) on an scrolling field (SField)
How can i put text into that field (with the name afield)?
put "xxx" into aField creates an error no such chunk
Re: How to adress a field wich is on another field
Hi Rene,
you have to tell Livecode what kind of object you want to address AND its name!
...
put "xxx" into FIELD "aField"
## can also be abbreviated with: fld
## less typing
...
And the names always in quotes as in my example!
Best
Klaus
you have to tell Livecode what kind of object you want to address AND its name!
...
put "xxx" into FIELD "aField"
## can also be abbreviated with: fld
## less typing

...
And the names always in quotes as in my example!
Best
Klaus
Re: How to adress a field wich is on another field
Thanks,
but that won't do the trick, in my actual code I did use quotes
but that won't do the trick, in my actual code I did use quotes
Re: How to adress a field wich is on another field
Rene,
the quotes around names of objects are highly recommended. But the problem with your script was not the quotes but, what Klaus pointed out in his script:
put "something" into ObjectType "objectName"
regards
Bernd
the quotes around names of objects are highly recommended. But the problem with your script was not the quotes but, what Klaus pointed out in his script:
you did not indicate the kind of object you want to put "xxx" into, you just said aField. This is the name of the object. You have to reference the field also.put "xxx" into FIELD "aField"
put "something" into ObjectType "objectName"
regards
Bernd
Re: How to adress a field which is on another field
Thank you Bernd,
But that's not the problem too, i do use put "something" into ObjectType "objectName"
I just didn't quote it right her in the forum, sorry.
I think I need something like this:
put ""xx" into field "AField" of field "SField"
If i use this i get an error : (Chunk: bad chunk order (must be small to large))
But that's not the problem too, i do use put "something" into ObjectType "objectName"
I just didn't quote it right her in the forum, sorry.
I think I need something like this:
put ""xx" into field "AField" of field "SField"
If i use this i get an error : (Chunk: bad chunk order (must be small to large))
Re: How to adress a field wich is on another field
Rene,
I am afraid I don't understand what you are doing.
What I get is: you overlay field "aField" on top of the scrolling field "SField" If that is the case Klaus code should work.
If it does not then there must be something else that is going wrong.
I think it is a problem of terminology/describing what exactly you want to do.
Kind regards
Bernd
I am afraid I don't understand what you are doing.
I you zip the stack you can upload it to the forum and I think it will be clearer what you want to do.I have put a field (aField) on an scrolling field (SField)
What I get is: you overlay field "aField" on top of the scrolling field "SField" If that is the case Klaus code should work.
If it does not then there must be something else that is going wrong.
I think it is a problem of terminology/describing what exactly you want to do.
Kind regards
Bernd
Re: How to adress a field wich is on another field
Hi renevanp,
You can't refer to a field by means of another field. Field "x" of field "y" is impossible. The question is: why do you want to do this? If you can explain that, we might provide you with a better solution.
Kind regards,
Mark
You can't refer to a field by means of another field. Field "x" of field "y" is impossible. The question is: why do you want to do this? If you can explain that, we might provide you with a better solution.
Kind regards,
Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
Re: How to adress a field wich is on another field
maybe one field is showing above the other field, covering it (partly) up?
then you'd need to check the location of the fields in regards to each other, for example with the within function or the intersect function (look them up in the dictionary).
then you'd need to check the location of the fields in regards to each other, for example with the within function or the intersect function (look them up in the dictionary).
Various teststacks and stuff:
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode
Re: How to adress a field wich is on another field
Hi All,
Thanks for the input
What I want(ed) is a Scrolling field containing a (large) number of fields, so I would be able to scroll down.
Just like you can put field directly on a card, I thought you could place a field on a scrolling list
I see now that you can't make a field part of a scrolling field.
Is there another way of achieving my goal?
I will look again at my code and try to figure out why I was not able to put something in my field named "afield"
Thanks for the input
What I want(ed) is a Scrolling field containing a (large) number of fields, so I would be able to scroll down.
Just like you can put field directly on a card, I thought you could place a field on a scrolling list
I see now that you can't make a field part of a scrolling field.
Is there another way of achieving my goal?
I will look again at my code and try to figure out why I was not able to put something in my field named "afield"
Re: How to adress a field wich is on another field
Hi renevanp ,
Just make a group of all your fields. Set the lockLoc of your group to true and add vertical and horizontal scroll bars (use the property inspector).
Kind regards,
Mark
Just make a group of all your fields. Set the lockLoc of your group to true and add vertical and horizontal scroll bars (use the property inspector).
Kind regards,
Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
Re: How to adress a field wich is on another field
Thank you Mark