Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.clipper.visual-objects > #13748 > unrolled thread

Self:Delete() causes a processor stack error

Started byDavid Linda <dlinda2011@gmail.com>
First post2023-01-19 10:44 -0800
Last post2023-01-23 11:00 +0200
Articles 11 — 6 participants

Back to article view | Back to comp.lang.clipper.visual-objects


Contents

  Self:Delete() causes a processor stack error David Linda <dlinda2011@gmail.com> - 2023-01-19 10:44 -0800
    Re: Self:Delete() causes a processor stack error JohnMartens <martens@tennishulp.info> - 2023-01-19 19:52 +0100
    Re: Self:Delete() causes a processor stack error Jamal <nospam@example.com> - 2023-01-19 22:41 -0500
      Re: Self:Delete() causes a processor stack error David Linda <dlinda2011@gmail.com> - 2023-01-20 07:35 -0800
        Re: Self:Delete() causes a processor stack error Robert van der Hulst <rjvanderhulst@gmail.com> - 2023-01-20 08:00 -0800
          Re: Self:Delete() causes a processor stack error David Linda <dlinda2011@gmail.com> - 2023-01-20 08:23 -0800
            Re: Self:Delete() causes a processor stack error Robert van der Hulst <rjvanderhulst@gmail.com> - 2023-01-20 08:53 -0800
              Re: Self:Delete() causes a processor stack error David Linda <dlinda2011@gmail.com> - 2023-01-20 09:15 -0800
                Re: Self:Delete() causes a processor stack error Chris Pyrgas <"chris (at)"@xsharp.eu> - 2023-01-21 10:45 +0200
                  Re: Self:Delete() causes a processor stack error Karl Faller <mail_withoutthat_@_drei-f_andthat_.de> - 2023-01-22 11:18 +0100
                    Re: Self:Delete() causes a processor stack error Chris Pyrgas <"chris (at)"@xsharp.eu> - 2023-01-23 11:00 +0200

#13748 — Self:Delete() causes a processor stack error

FromDavid Linda <dlinda2011@gmail.com>
Date2023-01-19 10:44 -0800
SubjectSelf:Delete() causes a processor stack error
Message-ID<c72c33ac-a391-434b-a9a2-724a053ec265n@googlegroups.com>
I find this error to be very curious, I have a data window.  My intention is to create a basic add, edit, delete app and the code in my delete button contains the following code:

Self:Delete()

I get a processor stack error.  While debugging I see the delete code execute over and over until I get the error.  I don't understand why the code executes over nd over, and the delete never occurs!

Any ideas...thank you,

David

[toc] | [next] | [standalone]


#13749

FromJohnMartens <martens@tennishulp.info>
Date2023-01-19 19:52 +0100
Message-ID<tqc3i0$1llee$1@dont-email.me>
In reply to#13748
Whats pahhens when you do a lokc() before the delete()
John


Op 19-1-2023 om 19:44 schreef David Linda:
> I find this error to be very curious, I have a data window.  My intention is to create a basic add, edit, delete app and the code in my delete button contains the following code:
> 
> Self:Delete()
> 
> I get a processor stack error.  While debugging I see the delete code execute over and over until I get the error.  I don't understand why the code executes over nd over, and the delete never occurs!
> 
> Any ideas...thank you,
> 
> David

[toc] | [prev] | [next] | [standalone]


#13750

FromJamal <nospam@example.com>
Date2023-01-19 22:41 -0500
Message-ID<tqd2gq$15g7$1@gioia.aioe.org>
In reply to#13748
Most likely you are calling the method in a **recursive loop**.

Need better help?

Go the X# forum at www.xsharp.eu and upload and a complete minimal AEF, 
with all related files, which duplicates the issue.

I suggest you always provide the VO version, Window version, etc.

Also, if a post helps you, then say so. It's a good for others to see if 
the issue is resolved in case they run into the same problem.


Jamal

On 1/19/2023 1:44 PM, David Linda wrote:
> I find this error to be very curious, I have a data window.  My intention is to create a basic add, edit, delete app and the code in my delete button contains the following code:
> 
> Self:Delete()
> 
> I get a processor stack error.  While debugging I see the delete code execute over and over until I get the error.  I don't understand why the code executes over nd over, and the delete never occurs!
> 
> Any ideas...thank you,
> 
> David

[toc] | [prev] | [next] | [standalone]


#13751

FromDavid Linda <dlinda2011@gmail.com>
Date2023-01-20 07:35 -0800
Message-ID<2870437d-6749-4415-b6b3-c2a706ccd8c8n@googlegroups.com>
In reply to#13750
On Thursday, January 19, 2023 at 10:41:16 PM UTC-5, Jamal wrote:
> Most likely you are calling the method in a **recursive loop**. 
> 
> Need better help? 
> 
> Go the X# forum at www.xsharp.eu and upload and a complete minimal AEF, 
> with all related files, which duplicates the issue. 
> 
> I suggest you always provide the VO version, Window version, etc. 
> 
> Also, if a post helps you, then say so. It's a good for others to see if 
> the issue is resolved in case they run into the same problem. 
> 
> 
> Jamal
> On 1/19/2023 1:44 PM, David Linda wrote: 
> > I find this error to be very curious, I have a data window. My intention is to create a basic add, edit, delete app and the code in my delete button contains the following code: 
> > 
> > Self:Delete() 
> > 
> > I get a processor stack error. While debugging I see the delete code execute over and over until I get the error. I don't understand why the code executes over nd over, and the delete never occurs! 
> > 
> > Any ideas...thank you, 
> > 
> > David

I have a Delete button that contains this code:

Self:Delete()

I am using Virtalbox
windows 3.1
V.O. 1.0

[toc] | [prev] | [next] | [standalone]


#13752

FromRobert van der Hulst <rjvanderhulst@gmail.com>
Date2023-01-20 08:00 -0800
Message-ID<c33a1778-e680-48f9-ab6b-f2d8112388d1n@googlegroups.com>
In reply to#13751
David,
Is the method that contains this code also called Delete ?
In that case:
- you do not need that method at all
- or you change the code to SUPER:Delete()

Robert

> On Thursday, January 19, 2023 at 10:41:16 PM UTC-5, Jamal wrote: 
> > Most likely you are calling the method in a **recursive loop**. 
> > 
> > Need better help? 
> > 
> > Go the X# forum at www.xsharp.eu and upload and a complete minimal AEF, 
> > with all related files, which duplicates the issue. 
> > 
> > I suggest you always provide the VO version, Window version, etc. 
> > 
> > Also, if a post helps you, then say so. It's a good for others to see if 
> > the issue is resolved in case they run into the same problem. 
> > 
> > 
> > Jamal 
> > On 1/19/2023 1:44 PM, David Linda wrote: 
> > > I find this error to be very curious, I have a data window. My intention is to create a basic add, edit, delete app and the code in my delete button contains the following code: 
> > > 
> > > Self:Delete() 
> > > 
> > > I get a processor stack error. While debugging I see the delete code execute over and over until I get the error. I don't understand why the code executes over nd over, and the delete never occurs! 
> > > 
> > > Any ideas...thank you, 
> > > 
> > > David
> I have a Delete button that contains this code: 
> 
> Self:Delete() 
> 
> I am using Virtalbox 
> windows 3.1 
> V.O. 1.0

[toc] | [prev] | [next] | [standalone]


#13753

FromDavid Linda <dlinda2011@gmail.com>
Date2023-01-20 08:23 -0800
Message-ID<55b419dc-ac45-489e-8643-7762892da930n@googlegroups.com>
In reply to#13752
On Friday, January 20, 2023 at 11:00:21 AM UTC-5, Robert van der Hulst wrote:
> David, 
> Is the method that contains this code also called Delete ? 
> In that case: 
> - you do not need that method at all 
> - or you change the code to SUPER:Delete() 
> 
> Robert
> > On Thursday, January 19, 2023 at 10:41:16 PM UTC-5, Jamal wrote: 
> > > Most likely you are calling the method in a **recursive loop**. 
> > > 
> > > Need better help? 
> > > 
> > > Go the X# forum at www.xsharp.eu and upload and a complete minimal AEF, 
> > > with all related files, which duplicates the issue. 
> > > 
> > > I suggest you always provide the VO version, Window version, etc. 
> > > 
> > > Also, if a post helps you, then say so. It's a good for others to see if 
> > > the issue is resolved in case they run into the same problem. 
> > > 
> > > 
> > > Jamal 
> > > On 1/19/2023 1:44 PM, David Linda wrote: 
> > > > I find this error to be very curious, I have a data window. My intention is to create a basic add, edit, delete app and the code in my delete button contains the following code: 
> > > > 
> > > > Self:Delete() 
> > > > 
> > > > I get a processor stack error. While debugging I see the delete code execute over and over until I get the error. I don't understand why the code executes over nd over, and the delete never occurs! 
> > > > 
> > > > Any ideas...thank you, 
> > > > 
> > > > David 
> > I have a Delete button that contains this code: 
> > 
> > Self:Delete() 
> > 
> > I am using Virtalbox 
> > windows 3.1 
> > V.O. 1.0


Holy Crap! 

Robert it worked, But I don't understand...Self is my datawindow, super gets me to the app level, as I under stand this, which is why I don't understand.  A more detailed explanation would be GREATLY appreciated.

Many thanks,

David

[toc] | [prev] | [next] | [standalone]


#13754

FromRobert van der Hulst <rjvanderhulst@gmail.com>
Date2023-01-20 08:53 -0800
Message-ID<980ec5cf-c08a-4296-908e-947c366156f9n@googlegroups.com>
In reply to#13753
David,

You are confusing SUPER with OWNER

SUPER is the DataWindow class from which your class inherits.
OWNER is the Shellwindow class (if your window is inside a shellwindow)

Robert

> On Friday, January 20, 2023 at 11:00:21 AM UTC-5, Robert van der Hulst wrote: 
> > David, 
> > Is the method that contains this code also called Delete ? 
> > In that case: 
> > - you do not need that method at all 
> > - or you change the code to SUPER:Delete() 
> > 
> > Robert 
> > > On Thursday, January 19, 2023 at 10:41:16 PM UTC-5, Jamal wrote: 
> > > > Most likely you are calling the method in a **recursive loop**. 
> > > > 
> > > > Need better help? 
> > > > 
> > > > Go the X# forum at www.xsharp.eu and upload and a complete minimal AEF, 
> > > > with all related files, which duplicates the issue. 
> > > > 
> > > > I suggest you always provide the VO version, Window version, etc. 
> > > > 
> > > > Also, if a post helps you, then say so. It's a good for others to see if 
> > > > the issue is resolved in case they run into the same problem. 
> > > > 
> > > > 
> > > > Jamal 
> > > > On 1/19/2023 1:44 PM, David Linda wrote: 
> > > > > I find this error to be very curious, I have a data window. My intention is to create a basic add, edit, delete app and the code in my delete button contains the following code: 
> > > > > 
> > > > > Self:Delete() 
> > > > > 
> > > > > I get a processor stack error. While debugging I see the delete code execute over and over until I get the error. I don't understand why the code executes over nd over, and the delete never occurs! 
> > > > > 
> > > > > Any ideas...thank you, 
> > > > > 
> > > > > David 
> > > I have a Delete button that contains this code: 
> > > 
> > > Self:Delete() 
> > > 
> > > I am using Virtalbox 
> > > windows 3.1 
> > > V.O. 1.0
> Holy Crap! 
> 
> Robert it worked, But I don't understand...Self is my datawindow, super gets me to the app level, as I under stand this, which is why I don't understand. A more detailed explanation would be GREATLY appreciated. 
> 
> Many thanks, 
> 
> David

[toc] | [prev] | [next] | [standalone]


#13755

FromDavid Linda <dlinda2011@gmail.com>
Date2023-01-20 09:15 -0800
Message-ID<892ecd3f-ebe1-4c50-b0e8-df5e3cbf1c0bn@googlegroups.com>
In reply to#13754
On Friday, January 20, 2023 at 11:53:58 AM UTC-5, Robert van der Hulst wrote:
> David, 
> 
> You are confusing SUPER with OWNER 
> 
> SUPER is the DataWindow class from which your class inherits. 
> OWNER is the Shellwindow class (if your window is inside a shellwindow) 
> 
> Robert
> > On Friday, January 20, 2023 at 11:00:21 AM UTC-5, Robert van der Hulst wrote: 
> > > David, 
> > > Is the method that contains this code also called Delete ? 
> > > In that case: 
> > > - you do not need that method at all 
> > > - or you change the code to SUPER:Delete() 
> > > 
> > > Robert 
> > > > On Thursday, January 19, 2023 at 10:41:16 PM UTC-5, Jamal wrote: 
> > > > > Most likely you are calling the method in a **recursive loop**. 
> > > > > 
> > > > > Need better help? 
> > > > > 
> > > > > Go the X# forum at www.xsharp.eu and upload and a complete minimal AEF, 
> > > > > with all related files, which duplicates the issue. 
> > > > > 
> > > > > I suggest you always provide the VO version, Window version, etc. 
> > > > > 
> > > > > Also, if a post helps you, then say so. It's a good for others to see if 
> > > > > the issue is resolved in case they run into the same problem. 
> > > > > 
> > > > > 
> > > > > Jamal 
> > > > > On 1/19/2023 1:44 PM, David Linda wrote: 
> > > > > > I find this error to be very curious, I have a data window. My intention is to create a basic add, edit, delete app and the code in my delete button contains the following code: 
> > > > > > 
> > > > > > Self:Delete() 
> > > > > > 
> > > > > > I get a processor stack error. While debugging I see the delete code execute over and over until I get the error. I don't understand why the code executes over nd over, and the delete never occurs! 
> > > > > > 
> > > > > > Any ideas...thank you, 
> > > > > > 
> > > > > > David 
> > > > I have a Delete button that contains this code: 
> > > > 
> > > > Self:Delete() 
> > > > 
> > > > I am using Virtalbox 
> > > > windows 3.1 
> > > > V.O. 1.0 
> > Holy Crap! 
> > 
> > Robert it worked, But I don't understand...Self is my datawindow, super gets me to the app level, as I under stand this, which is why I don't understand. A more detailed explanation would be GREATLY appreciated. 
> > 
> > Many thanks, 
> > 
> > David
Oh yes...So then similarly my add code should be IF super:Append() = TRUE instead of IF Self:Append() = TRUE which is what I have now
This was also confusing because Self:Append()   worked and Self:Delete   did not.  Thanks again

  

[toc] | [prev] | [next] | [standalone]


#13756

FromChris Pyrgas <"chris (at)"@xsharp.eu>
Date2023-01-21 10:45 +0200
Message-ID<tqg8nj$q2o$1@gioia.aioe.org>
In reply to#13755
Hi David,

> On Friday, January 20, 2023 at 11:53:58 AM UTC-5, Robert van der Hulst wrote:
>> David,
>>
>> You are confusing SUPER with OWNER
>>
>> SUPER is the DataWindow class from which your class inherits.
>> OWNER is the Shellwindow class (if your window is inside a shellwindow)
>>
>> Robert
>>> On Friday, January 20, 2023 at 11:00:21 AM UTC-5, Robert van der Hulst wrote:
>>>> David,
>>>> Is the method that contains this code also called Delete ?
>>>> In that case:
>>>> - you do not need that method at all
>>>> - or you change the code to SUPER:Delete()
>>>>
>>>> Robert
>>>>> On Thursday, January 19, 2023 at 10:41:16 PM UTC-5, Jamal wrote:
>>>>>> Most likely you are calling the method in a **recursive loop**.
>>>>>>
>>>>>> Need better help?
>>>>>>
>>>>>> Go the X# forum at www.xsharp.eu and upload and a complete minimal AEF,
>>>>>> with all related files, which duplicates the issue.
>>>>>>
>>>>>> I suggest you always provide the VO version, Window version, etc.
>>>>>>
>>>>>> Also, if a post helps you, then say so. It's a good for others to see if
>>>>>> the issue is resolved in case they run into the same problem.
>>>>>>
>>>>>>
>>>>>> Jamal
>>>>>> On 1/19/2023 1:44 PM, David Linda wrote:
>>>>>>> I find this error to be very curious, I have a data window. My intention is to create a basic add, edit, delete app and the code in my delete button contains the following code:
>>>>>>>
>>>>>>> Self:Delete()
>>>>>>>
>>>>>>> I get a processor stack error. While debugging I see the delete code execute over and over until I get the error. I don't understand why the code executes over nd over, and the delete never occurs!
>>>>>>>
>>>>>>> Any ideas...thank you,
>>>>>>>
>>>>>>> David
>>>>> I have a Delete button that contains this code:
>>>>>
>>>>> Self:Delete()
>>>>>
>>>>> I am using Virtalbox
>>>>> windows 3.1
>>>>> V.O. 1.0
>>> Holy Crap!
>>>
>>> Robert it worked, But I don't understand...Self is my datawindow, super gets me to the app level, as I under stand this, which is why I don't understand. A more detailed explanation would be GREATLY appreciated.
>>>
>>> Many thanks,
>>>
>>> David
> Oh yes...So then similarly my add code should be IF super:Append() = TRUE instead of IF Self:Append() = TRUE which is what I have now
> This was also confusing because Self:Append()   worked and Self:Delete   did not.  Thanks again

The problem with the Delete() method was that you named the method that 
was calling Delete(), also "Delete", something like that:

METHOD Delete() CLASS ...
SELF:Delete()

so that code in line 2 was calling the same method itself again and 
again. Using SUPER instead of SELF, you tell the compiler that you want 
to call the same named method that is called one level lower in the 
class hierarchy, so there's no recursive call anymore.

It's the same with Append(), if you were calling it from a same named 
method like this:

METHOD Append() CLASS ...
SELF:Delete() // recursive call

then you woudl have again the same problem.

Btw, are you really using VO 1.0 and Win 3.1 (in a virtual machine) as 
you mentioned in one of your previous posts?

Chris


[toc] | [prev] | [next] | [standalone]


#13757

FromKarl Faller <mail_withoutthat_@_drei-f_andthat_.de>
Date2023-01-22 11:18 +0100
Message-ID<2b3qshhqlarek0kp5g3a1fqg0asi61fpor@4ax.com>
In reply to#13756
On Sat, 21 Jan 2023 10:45:40 +0200, Chris Pyrgas wrote:

>METHOD Append() CLASS ...
>SELF:Delete() // recursive call
>
>then you woudl have again the same problem.
FTR, Chris, this should be:

METHOD Append() CLASS ...
SELF:Append() // recursive call
>
Regards

Karl

[toc] | [prev] | [next] | [standalone]


#13759

FromChris Pyrgas <"chris (at)"@xsharp.eu>
Date2023-01-23 11:00 +0200
Message-ID<tqlibe$57s$1@gioia.aioe.org>
In reply to#13757
Thanks Karl :)

On 22/01/2023 12:18, Karl Faller wrote:
> On Sat, 21 Jan 2023 10:45:40 +0200, Chris Pyrgas wrote:
> 
>> METHOD Append() CLASS ...
>> SELF:Delete() // recursive call
>>
>> then you woudl have again the same problem.
> FTR, Chris, this should be:
> 
> METHOD Append() CLASS ...
> SELF:Append() // recursive call
>>
> Regards
> 
> Karl
> 

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.clipper.visual-objects


csiph-web