Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Mdot question
Message
From
15/04/2021 11:22:37
Lutz Scheffler
Lutz Scheffler Software Ingenieurbüro
Dresden, Germany
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
01679493
Message ID:
01679812
Views:
48
>>>>>>>IMO, mdot is largely a matter of VFP folklore. Wake me up when it gets to Fox vs Clipper, or even better, Spectrum vs Commodore.
>>>>>>
>>>>>>Now you are allowed to guess the side I choose.
>>>>>>;)
>>>>>
>>>>>Fine. Be stupid. I inherited lots of supposedly genius programmers over the years. All that allowed me to function was using m. as needed by the compiler. I currently have a table called latest. It is opened by a query. Then a scatter name is used. Then they use m.latest.fieldname. So, there goes any possible use of m.arrayname.
>>>>>
>>>>>If I write a piece of code for you to use, it will not break because of your table/field naming conventions. If you give me a piece of code, I am certain it will. This is the real world, not your isolated bubble.
>>>>
>>>>
>>>>So....what you're really complaining about is that m.tablename.fieldname, which is the incorrect usage of m. (iirc). If yer gonna use a scatter memvar, then the correct usage would be m.fieldname. I simply consider it legacy code and when I used to run into it, after some minor research, it would be code that was written in FPD and had been ported through the versions, hopefully skipping FPW.
>>>
>>>No, he uses "scatter name latest" (no scatter memvar), thus an object called "latest" is created and the he can either access the cursor ("latest.fieldname") or the object ("m.latest.fieldname"), I would try to avoid doing that because of it's human ambiguity when reading the code, but it is just preference. In my case I normally use loRecord ("scatter name loRecord") as the variable will be very short lived (local on a small function that has a single purpose, so I do not need to name the variable the same as the source alias, but if I wanted then I would use lo{Alias}Record, for example in this case loLatestRecord)
>>
>>I would change the code. This is better then adding the mdot to the wrong symbol .... There is simply no need to name the object like the cursor.
>>
>>This all is odd. I started this because I run into small trouble with BeautifyX and it's mdot option - it killed ancient code using INSERT FROM MEMVAR and a SQL SELCT by adding mdot to the right hand of AS in SELECT SQL. I was thinking on how to fix BeautifyX and found some stuff to procrastinate about the SELECT SQL problem.
>>The real odd is nobody on all the fuzz was able to give a straight answer to the initial question.
>>
>>(-‸ლ)
>
>I did not even read your question yet, it has been a while since I last logged into levelextreme, and this thread was "chopped" and this is the branch where it started for me, sorry

Awww. No, it was not meant this way. I know you've answered late. It was more general ..
Words are given to man to enable him to conceal his true feelings.
Charles Maurice de Talleyrand-Périgord

Weeks of programming can save you hours of planning.

Off

There is no place like [::1]
Previous
Reply
Map
View

Click here to load this message in the networking platform