from the FP Room today...
John Esak
alpha at valar.com
Tue May 2 16:57:31 PDT 2006
That's okay... glad I could help.... but did you catch the "fix" I put on
the list... It is supposed to fill the numbered field with (value) not
(field)... when I fixed the prc I forgot to fix all of it. Then Ken Brody
posted a 3 line subroutine that is WAY better than doing it with a gosub
for each and every field. By building the array the way he showed it does
ALL fields no matter which one is chosen. It will work on 4.8, too... just
take out the declared filed and value and use fd(3,.0) and va(30,,*) or
something like that.
John
-----Original Message-----
From: SmittyUSN1 at aol.com [mailto:SmittyUSN1 at aol.com]
Sent: Tuesday, May 02, 2006 4:12 PM
To: alpha at valar.com
Subject: Re: from the FP Room today...
Thanks for putting that processing up today John, I copied it too
notepad and then to a filePro prc. table, it almost worked but the syntax
was off and I am in the process of moving the text around so fp will be
happy with it, I will try to test it tonite or tommorow.
The request was pretty simple, I'm sure there are bigger and better ways
to do this, the below way is how the customer presented the question too me
yesterday.
In an output process, select X number of records, then ASK for
which field NUMBER to change data in.
SHOW records found & field description, INPUT new DATA for that field...
Verify all in a INPUT OK to POST Y/N? if Y take off and fix those
fields that it found in the selection set......
I am most comfortable with 4.8 processing .. gulp... i know, i know ...
Pretty Simple ...Huh ...
Laugh .. Thanks Again ... Wayne & Scott
cc this to SmittyUSN1 at Bellsouth.net please .. and please dont put
this on the list for that bozo fairy to flame me.
In a message dated 5/2/2006 2:03:09 PM Eastern Daylight Time,
alpha at valar.com writes:
Yes,
Below (your change) is a much better way to do this... but, I was just
giving the idea of what needed to be done to some folks who asked the
question. It was something I put up in about 2 minutes, and I wasn't
sure at
first if the fields were contiguous or differing edit types. I thought
briefly about showing it as an array, but it added that one level of
complexity. Actually, it is not only less complex, but eliminates any
other
coding and covers the whole file. The only thing I was going to shoot
for
next that I knew the array couldn't handle was adding an edit type to
(value). At least, I didn't want to thrash out how important edit
validation
was going to be. I was on my way into a conference call and under the
gun.
John
P.S. - Those are my excuses for not showing them the best way to do
this...
did I mention also that the sun was in my eyes and my shoes were too
tight... also?? :-)
> -----Original Message-----
> From: Kenneth Brody [mailto:kenbrody at bestweb.net]
> Sent: Tuesday, May 02, 2006 1:10 PM
> To: alpha at valar.com
> Cc: Fplist (E-mail)
> Subject: Re: from the FP Room today...
>
>
> Quoting John Esak (Tue, 2 May 2006 12:34:33 -0400):
>
> >
> >
> > To the guys who were in the FP Room today... you probably figured it
> > out...
> > but here is the corrected prc.table. It posts (value) to the
designated
> > field. Hope you caught that.
> > JE
> >
> >
> > :field ne "":goto doit:
> > ::declare field(3,.0,g), value(30,*,g):
> > ask_f::input popup field "Which field do you want to modify? ":
> > :@sk eq "BRKY":exit:
> > :field eq "":goto ask_f:
> > ask_v::input popup value "What value do you want to put in this
field?
> > ":
> > :@sk eq "BRKY":exit:
> > doit:'doit::
> > ::gosub (field) of do_1, do_2, do_3:
> > ::end:
> > do_1:'do_1::
> > ::1=value; return:
> > do_2:'do_2::
> > ::2=value; return:
> > do_3:'do_3::
> > ::3=value; return:
>
> I wasn't in the room, so perhaps you are doing more than is apparent
> by just looking at this snippet.
>
> However, why not just replace the doit lines with:
>
> doit
> Then: dim MyRecord[3]:1
> If: field gt "0" and field le "3"
> Then: MyRecord[field] = value
> Then: end
>
> The "if" line can be eliminated if you pre-check "field" for valid
> values.
>
> --
> KenBrody at BestWeb dot net spamtrap:
<g8ymh8uf001 at sneakemail.com>
> http://www.hvcomputer.com
> http://www.fileProPlus.com
_______________________________________________
Filepro-list mailing list
Filepro-list at lists.celestial.com
http://mailman.celestial.com/mailman/listinfo
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.celestial.com/pipermail/filepro-list/attachments/20060502/d84cf4b7/attachment.html
More information about the Filepro-list
mailing list