Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
New method
Message
De
26/04/2005 02:56:36
 
 
À
25/04/2005 08:03:45
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Versions des environnements
Visual FoxPro:
VFP 5
Database:
Visual FoxPro
Divers
Thread ID:
01007918
Message ID:
01008351
Vues:
17
hi,
thank you,
i try as under, i can move for all columns and records, accept the first column,if i insert any character i can't return pack to this column,to change it ,some times i need to return pack...,
if thisform.grid1.column1.text1.value>SPACE(10)
     UPDATE temp set sum1=d1+d2+d3+d4+d5+d6+d7+d8+d9+d10,;
     sum2=d11+d22+d33+d44+d55+d66+d77+d88+d99,;
     sum3=iif(d1+d2+d3+d4+d5+d6+d7+d8+d9+d10=0 or d1+d2+d3+d4+d5+d6+d7+d8+d9+d10=0,0,(sum2/sum1)*100)
     thisform.grid1.refresh()
endif
thanks.
>Try to block out the update whenever you want it not to happen
>
>if something
>  UPDATE temp set sum1=d1+d2+d3+d4+d5+d6+d7+d8+d9+d10,;
>    sum2=d11+d22+d33+d44+d55+d66+d77+d88+d99,;
>    sum3=iif(d1+d2+d3+d4+d5+d6+d7+d8+d9+d10=0 or   d1+d2+d3+d4+d5+d6+d7+d8+d9+d10=0,0,(sum2/sum1)*100)
>  thisform.grid1.refresh()
>endif
>>hi,
>>but when i remove the code under,
>>it works
>>
>>UPDATE temp set sum1=d1+d2+d3+d4+d5+d6+d7+d8+d9+d10,;
>>  sum2=d11+d22+d33+d44+d55+d66+d77+d88+d99,;
>>  sum3=iif(d1+d2+d3+d4+d5+d6+d7+d8+d9+d10=0 or   d1+d2+d3+d4+d5+d6+d7+d8+d9+d10=0,0,(sum2/sum1)*100)
>>thisform.grid1.refresh()
>>
>>
>>>Then I don't know what's happening. Since my line of code updates all the records in the table, and the table is bound to the grid, something else in your code must cause the problem.
>>>
>>>>hi,
>>>>still same.
>>>>
>>>>>Don't use thisform.grid1.refresh(), use this.refresh(). I don't know if this is the reason for your error, though.
>>>>>
>>>>>>hi,
>>>>>>i try but still,
>>>>>>
>>>>>>LPARAMETERS nColIndex
>>>>>>
>>>>>> thisform.text4.value=thisform.grid1.column2.text1.value
>>>>>>   select  mac1
>>>>>> locate for nam=upper(alltrim(thisform.text4.value))
>>>>>> thisform.text2.value=mac1.dvno
>>>>>> select temp
>>>>>>thisform.grid2.visible=.t.
>>>>>>thisform.Grid2.RecordSource=SPACE(0)
>>>>>>select nam,macwork1 from mac1;
>>>>>>         where dvno = thisform.text2.Value ;
>>>>>>      into cursor crsMyCursor
>>>>>>thisform.Grid2.RecordSource="crsMyCursor"
>>>>>>
>>>>>>UPDATE temp set sum1=d1+d2+d3+d4+d5+d6+d7+d8+d9+d10,;
>>>>>>  sum2=d11+d22+d33+d44+d55+d66+d77+d88+d99,;
>>>>>>  sum3=iif(d1+d2+d3+d4+d5+d6+d7+d8+d9+d10=0 or d1+d2+d3+d4+d5+d6+d7+d8+d9+d10=0,0,(sum2/sum1)*100)
>>>>>>thisform.grid1.refresh()
>>>>>>
>>>>>>
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform