Hi Robert, Team, Frank and all,
Please can you help me with some suitable syntax for an interface I am converting from Nick's C# code.
I have been translating his code all afternoon and think I have become 'code blind' and/or my brain has frozen ;-0)
Since I have limited experience with Interfaces please guide me.
The attached and inserted image clips should be enough detail for the experienced guys amongst you.
The above is what I start with.
Here is what I tried :-
And here are a couple of images to help :-
Previously, I have managed with interfaces with only methods, and in Nick's code I think this is the first one with what looks to me like a property.
HELP !!!
Phil.
Wales, UK.
Interface syntax ? - C# to X#
-
- Posts: 178
- Joined: Sat Dec 05, 2015 10:44 am
- Location: Germany
Interface syntax ? - C# to X#
Phil
Property DSDbEntityState as DSDbEntityState GET SET
Frank
Property DSDbEntityState as DSDbEntityState GET SET
Frank
- Phil Hepburn
- Posts: 743
- Joined: Sun Sep 11, 2016 2:16 pm
Interface syntax ? - C# to X#
Thanks a bunch Frank, it works just fine - see attached.
So why does auto not work ? Robert will need to give one of his 'deeper' explanations.
Well, onwards and upwards, I will keep testing the VS integration.
Have already found a few useful issues to feed back to the Team.
Best regards to all,
Phil.
Wales, UK.
So why does auto not work ? Robert will need to give one of his 'deeper' explanations.
Well, onwards and upwards, I will keep testing the VS integration.
Have already found a few useful issues to feed back to the Team.
Best regards to all,
Phil.
Wales, UK.
Interface syntax ? - C# to X#
Phil,
The Auto clause is used to declare a property with an AUTOmatic backing field. Interface members cannot have backing fields.
I guess we could make AUTO a synonym for GET SET but I personally thing the syntax is OK at this moment.
Robert
The Auto clause is used to declare a property with an AUTOmatic backing field. Interface members cannot have backing fields.
I guess we could make AUTO a synonym for GET SET but I personally thing the syntax is OK at this moment.
Robert
XSharp Development Team
The Netherlands
robert@xsharp.eu
The Netherlands
robert@xsharp.eu
-
- Posts: 178
- Joined: Sat Dec 05, 2015 10:44 am
- Location: Germany
Interface syntax ? - C# to X#
Phil,
an interface says something about how to access a member. The AUTO clause says how it is actually implemented. These are two diferent things.
Robert, I would not allow AUTO because it's mixing up things.
Frank
an interface says something about how to access a member. The AUTO clause says how it is actually implemented. These are two diferent things.
Robert, I would not allow AUTO because it's mixing up things.
Frank
- Phil Hepburn
- Posts: 743
- Joined: Sun Sep 11, 2016 2:16 pm
Interface syntax ? - C# to X#
Hi and thanks Robert,
Yes, I understand, so the 'auto' is for an automatic backing field facility to be put in place - not just the 'get set' - makes sense as it is.
I will send to you directly a couple of things I discovered yesterday about the current VS integration. Not BIG issues but ones which should be addressed and corrected I feel, to improve the 'operation & look-feel' for others.
Power to my finger tips ! Have a nice day.
Cheers,
Phil.
Wales, UK.
Yes, I understand, so the 'auto' is for an automatic backing field facility to be put in place - not just the 'get set' - makes sense as it is.
I will send to you directly a couple of things I discovered yesterday about the current VS integration. Not BIG issues but ones which should be addressed and corrected I feel, to improve the 'operation & look-feel' for others.
Power to my finger tips ! Have a nice day.
Cheers,
Phil.
Wales, UK.
- Phil Hepburn
- Posts: 743
- Joined: Sun Sep 11, 2016 2:16 pm
Interface syntax ? - C# to X#
Frank,
... Agreed ...
Cheers,
Phil.
Wales, UK.
... Agreed ...
Cheers,
Phil.
Wales, UK.
Interface syntax ? - C# to X#
Please do not send them as images (with the exception of error dialogs of course), but as real text. That makes it much easier to reproduce the problems.Phil Hepburn wrote:H
I will send to you directly a couple of things I discovered yesterday about the current VS integration. Not BIG issues but ones which should be addressed and corrected I feel, to improve the 'operation & look-feel' for others.
Robert
XSharp Development Team
The Netherlands
robert@xsharp.eu
The Netherlands
robert@xsharp.eu
- Phil Hepburn
- Posts: 743
- Joined: Sun Sep 11, 2016 2:16 pm
Interface syntax ? - C# to X#
Oh! - if live were only so simple ;-0)
Thanks Robert, I will do my best !
Phil.
Thanks Robert, I will do my best !
Phil.