Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Add to table
Message
De
17/01/2005 20:20:07
 
 
À
17/01/2005 18:41:17
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Divers
Thread ID:
00977855
Message ID:
00977926
Vues:
19
>hi,
>thank you,
>i mean Dayname if the day is Friday,
> name of day becuse at this day worke stop
>i want to replace field rem with friday
>thanks
>
You have anywhere between 28 and 31 blank records in your table. Which of these do you want to have
REPLACE rem WITH "Friday"
>>It sounds as if you have a textbox which contains a date. When you press a button you want to insert however many blank records into a table as there are days in the month for that date.
>>
>>Here is some simple, not very elegant code to do that
>>
>>&& Make sure you have the proper table selected
>>ldDate = thisform.text2.value
>>lnMonth = MONTH(ldDate)
>>ldDate = ldDate - DAY(ldDate) + 1    && Make sure we are on the first day of the mont
>>DO WHILE lnMonth = MONTH(ldDate)
>>   APPEND BLANK
>>   &&  If you need to put specific values into a field, put the REPLACE statements here
>>   ldDate = ldDate + 1
>>ENDDO
>>
>>
>>I also don't understand what you mean by "Dayname if the day is Friday."
>>All that has happened above is creating blank records. If any of the fields need specific values, you will have to put code for that where I indicated.
>>
>>>hi ,
>>>i don't understand what you mean,
>>>but i need to insert at my thisform.text2.value ctod("01/01/2005")
>>>thanks.
>>>>Is the month you enter, always less than a year from now?
>>>>>hi,
>>>>>thank you,
>>>>>i try to do this as under ,it works as add 31 days,
>>>>>but i need to replace dayname if the day name is friday,
>>>>>and i want to add month(2) feb..to month(12),take care if thedays for every month is 31 , 30 or 29 or 28 if month is=2
>>>>>
>>>>>IF MONTH(thisform.text2.Value)=01
>>>>>  FOR n=1 TO 31
>>>>>   APPEND BLANK
>>>>>  endfor
>>>>>endif
>>>>>
>>>>>>Hi Mohammed,
>>>>>>
>>>>>>I don't mean to be rude, but I don't understand what you want.
>>>>>>Do you want 31 blank records? If so, under what conditions.
>>>>>>Why do you mention Friday?
>>>>>>Can you give us a better explanation?
>>>>>>>hi all,
>>>>>>>
>>>>>>>i need help to insert 31 records at my table if month e.i =1,if day is friday insert(replace) at myfield rem friday
>>>>>>>as
>>>>>>>31 append blank
>>>>>>>thanks.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform