Words:  

RE: alp problems

Date: 09-02-10
From: "Stephen J. Orth" <s.orth_at_the-aquila-group.com>

Chuck,

Regarding your other issue, instead of assigning the array element a null value, set it as follows:

PRT_Metail_as{vrow}:=PRT_Metail_as{0}

The prior value is stored in the zero element, and that is how I always rollback.


Steve

*****************************************************
Stephen J. Orth
The Aquila Group, Inc. Office: (608) 834-9213
P.O. Box 690 Mobile: (608) 347-6447
Sun Prairie, WI 53590

E-Mail: s.orth_at_the-aquila-group.com
*****************************************************



-----Original Message-----
From: 4d_tech-bounces_at_lists.4D.com [mailto:4d_tech-bounces_at_lists.4D.com] On Behalf Of Chuck Miller
Sent: Tuesday, February 09, 2010 7:20 PM
To: 4DTechList Tech
Subject: alp problems

Hi


I am having some problems, which I can not figure out.

Environment 4D 2004.8
ALP version 7.8.2

I have a multi page form with alp areas on some of the pages.

All pages use advanced properties to design and set alp areas.

On a new page I have 2 columns. Column 1 is where problem lies. It is
enterable only through a drop down.
I have tried manipulating the drop down in an entry call back by
adjusting values but when displaying form, it always shows as no
entries, OK so I tried filling drop down on output form. That works
but I can not allow two entries of the same type

The problem I ma having now is that even though I am setting
PRT_Metail_as{vrow} to "", it still displays as the choice made on the
screen

Thanks and Regards


Chuck
Given the following code used as call back


C_LONGINT($1;$2)
C_BOOLEAN($0;$AcceptEntry_b)
AL_GetCurrCell (eMetals;vcol;vrow)
If (vcol=1)

C_TEXT($vt_Metal)
$vt_Metal:=PRT_Metail_as{vrow}
$AcceptEntry_b:=True
For ($i;1;Size of array(PRT_Metail_as))
If ($i=vrow)
Else
If (PRT_Metail_as{$i}=$vt_Metal)
ALERT("You may not select "+$vt_Metal+" as it is already on this
part")
PRT_Metail_as{vrow}:=""
$AcceptEntry_b:=False
$i:=Size of array(PRT_Metail_as)+1
End if
End if
End for
If ($AcceptEntry_b)
AL_UpdateArrays (eMetals;-1)
AL_GotoCell (eMetals;2;vrow)
Else
◊AS_Metals:=0
AL_UpdateArrays (eMetals;-1)
AL_GotoCell (eMetals;1;vrow)
End if
Else
$AcceptEntry_b:=True
End if
$0:=$AcceptEntry_b


**********************************************************************
The New 4D Partner Program - All the tools you need to be a successful 4D Developer.
Sign up Now: http://www.4d.com/community/partner/registration.html


4D Internet Users Group (4D iNUG)
FAQ: http://lists.4d.com/faqnug.html
Archive: http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub: mailto:4D_Tech-Unsubscribe_at_lists.4D.com
**********************************************************************