Jump to content

Montly Job Schedule


alias92

Recommended Posts

i want to write an asp code like excel formi only choose person and month then a page openthat page has a month for example december01.12.2009 to 31.12.2009 and date days ie: monday, tuesday .... sundayi want only one page and i put the input text and i fill the form then i save it and add to db.please help me..my template is like following...dates days work1 work2 work3 notes-----------------------------------------------------------------------------------------------------01.12.2009 tuesday breakfast customer meeting driving notes etc..02.12.2009 wednesday works worksss worksss notesssss 03.12.2009 ...........................

Link to comment
Share on other sites

please help me

i want to write an asp code like excel formi only choose person and month then a page openthat page has a month for example december01.12.2009 to 31.12.2009 and date days ie: monday, tuesday .... sundayi want only one page and i put the input text and i fill the form then i save it and add to db.please help me..my template is like following...dates days work1 work2 work3 notes-----------------------------------------------------------------------------------------------------01.12.2009 tuesday breakfast customer meeting driving notes etc..02.12.2009 wednesday works worksss worksss notesssss 03.12.2009 ...........................
Link to comment
Share on other sites

There's a lot to do there, and I can't help you with everything. You know what data your system needs to handle, so you'll need to design the database to handle it. In terms of the code you need, you'll need form-processing code to handle the selections for the person and month, the code to get that person's schedule and display it with the forms to update things, and then the code to update the schedule in the database. So it sounds like you need at least 2 tables in the database, one of them to hold the user information and the other to hold the schedule information. You'll probably also need to do a login system if you want this to be password-protected.

Link to comment
Share on other sites

i do password protected login system and person table. but i cannot do schedule table. i want to choose person from person table and choose start and end date from select box then open a schedule page.that schedule page must be data grid. like an example before i send, i will be see and edit all records in one page.please help me on data grid page and db structure

Link to comment
Share on other sites

You'll print the results in a table, so the first thing for you to do is write a page that just loops between two dates (you don't have to pick them from a list, just hard-code the start and end dates) and have it print one line for each date. You can print the date in the first column and whatever other information in the other columns, like the day name. Don't worry about users and whatever else at this point, just work on the code to print one entry for each day between two dates. I've worked on a lot of scheduling and calendar applications and they all start with me figuring out how to write it out in the first place, without any database or anything else to complicate it.

Link to comment
Share on other sites

Don't worry about the database at this point, just get ASP to print a schedule. It doesn't need to have anything in it. Once you have the interface set up then you can worry about getting data from the database to fill in, or saving records to the database.

Link to comment
Share on other sites

<%dim date1, idate1 = "01.12.2009"Function getDaysInMonth(intMonth,intYear) strDate = intYear & "-" & intMonth & "-" & 1 numDays = -1 ' indicates error If IsDate(strDate) Then dDate = CDate(strDate) nextMonth = DateAdd("M",1,dDate) numDays = Day(DateAdd("D",-1,nextMonth)) End If getDaysInMonth = numDaysEnd FunctionFunction getBgcolor(weeks) Select Case (weeks) Case 2, 4, 6 : bgcolor = "#bbbbbb" Case 3, 5 : bgcolor = "#dddddd" Case 7 : bgcolor = "#f00000" Case 1 : bgcolor = "#990000" End Select getBgcolor = bgcolorEnd FunctionFunction getColor(weeks) Select Case (weeks) Case 2, 3, 4, 5, 6 : bgcolor = "#000000" Case 1, 7 : bgcolor = "#ffffff" End Select getColor = bgcolorEnd Function'Response.Write getDaysInMonth(Month(Date),Year(Date)) & "<br>"'Response.Write getDaysInMonth(2,2007) & "<br>"%><table><tr> <td>Sıra</td> <td>Tarih</td> <td>Gün</td> <td>İl</td> <td>İlçe 1</td> <td>İlçe 2</td> <td>İlçe 3</td> <td>Konak İl/İlçe</td> <td>Otel</td> <td>Not</td></tr><%for i = 1 to getDaysInMonth(Month(date1),year(date1))%><tr style="background:<%=getBgcolor(Weekday(DateAdd("d",i-1,date1)))%>; color:<%=getColor(Weekday(DateAdd("d",i-1,date1)))%>"> <td><%=i%></td> <td><%=DateAdd("d",i-1,date1)%></td> <td><%=WeekdayName(Weekday(DateAdd("d",i-1,date1)))%></td> <td><input type="text" name="il_<%=i%>"></td> <td><input type="text" name="ilce1_<%=i%>"></td> <td><input type="text" name="ilce2_<%=i%>"></td> <td><input type="text" name="ilce3_<%=i%>"></td> <td><input type="text" name="konakil_<%=i%>"></td> <td><input type="text" name="otel_<%=i%>"></td> <td><input type="text" name="not_<%=i%>"></td></tr><%next%></table>how can create db table and get input text and insert dbplease help me

Link to comment
Share on other sites

How you create the database depends on what database you're using. If you're using SQL Server for example, then you would use the Enterprise Manager to create your database and tables. Most database servers come with their own management tools to manage the databases. Once you have your database set up then you'll probably use the ADO library to connect with it. There's a link to the ADO tutorial on this page:http://www.w3schools.com/asp/asp_ado.asp

Link to comment
Share on other sites

  • 1 year later...

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...