Click here to Skip to main content
15,902,891 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
In that form collect week amount from customer for
current week only.Don't allow the user to pay the amount before one week
and next week.If the Amount is paid in the current week after that the
entry is in the next week only.

Can any one help me to generate this logic..

[edit]SHOUTING removed, spurious code block removed - OriginalGriff[/edit]
Updated 22-Feb-13 0:13am
Chris Reynolds (UK) 22-Feb-13 6:05am    
What have you tried so far? Have a go and then post what you've done - don't expect us to write all your work for you.
OriginalGriff 22-Feb-13 6:13am    
DON'T SHOUT. Using all capitals is considered shouting on the internet, and rude (using all lower case is considered childish). Use proper capitalisation if you want to be taken seriously.
ArunAmalraj 22-Feb-13 6:19am    
You can use the Calendar.GetWeekOfYear method to get the week number of a date

And allow to make payments only after ((week number)+1) weeks.
MalwareTrojan 25-Feb-13 0:43am    
You are using SQL, MySql or Oracle even specify its version.

1 solution

Get week from some date
Debug.Print(DateDiff(DateInterval.Weekday, DateValue(Now), datevalue($anydate$)))
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900