Hi!
I have a listbox using the code below. Only the first two values show. I created the listbox visually, set columncount to 3. I'm trying to use example from '1001 Things....'
The commented code above gives the correct 3 values, but I only get the first 2 in the listbox. I made sure the width of box was adequate and tried it with and without setting column widths.
Still on VFP 6.0 but moving to 9 next week
and I'm sure many, many questions will follow.
Any suggestions appreciated.
Judi
I have a listbox using the code below. Only the first two values show. I created the listbox visually, set columncount to 3. I'm trying to use example from '1001 Things....'
Code:
LOCAL lcJobsnumb, lcRowsource
lcJobsnumb = Thisform.pgfCasting.pagJobs.txtJobsnumb.Value
*!* SELECT Typebad.badno,Btypes.typedesc,
*!* SUM(Typebad.badqty) AS scrap ;
*!* FROM casting!typebad LEFT OUTER JOIN casting!btypes ;
*!* ON Typebad.badno = Btypes.badno ;
*!* WHERE ALLTRIM(typebad.jobsnumb) = lcJobsnumb ;
*!* ORDER BY Typebad.jobsnumb, Typebad.badno ;
*!* GROUP BY Typebad.badno INTO CURSOR csrtemp
lcRowSource = 'SELECT Typebad.badno,Btypes.typedesc, SUM(Typebad.badqty) as scrap '
lcRowSource = lcRowSource + 'FROM casting!typebad LEFT OUTER JOIN casting!btypes '
lcRowSource = lcRowSource + 'ON Typebad.badno = Btypes.badno '
lcRowSource = lcRowSource + 'WHERE alltrim(typebad.jobsnumb) = lcJobsnumb '
lcRowSource = lcRowSource + 'ORDER BY Typebad.jobsnumb, Typebad.badno '
lcRowSource = lcRowSource + 'GROUP BY Typebad.badno INTO CURSOR csrtemp'
WITH Thisform.pgfCasting.pagJobs.lstBadType
.RowSourceType = 3
.RowSource =lcRowSource
.Requery()
.ListIndex = 1
ENDWITH
Thisform.Refresh()
The commented code above gives the correct 3 values, but I only get the first 2 in the listbox. I made sure the width of box was adequate and tried it with and without setting column widths.
Still on VFP 6.0 but moving to 9 next week
![[bigsmile] [bigsmile] [bigsmile]](/data/assets/smilies/bigsmile.gif)
Any suggestions appreciated.
Judi