I would like to create form absence leave ,, please suggest - InfoPath Dev
in

InfoPath Dev

I would like to create form absence leave ,, please suggest

Last post 12-29-2010 06:14 AM by Patrick Halstead. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 12-24-2010 01:07 AM

    I would like to create form absence leave ,, please suggest

     I would like to create form absence leave in sharepoint by using infopath

    I create form by using infopath in Sharepoint From Library

    My form have function 

    1. input all field such employee name, type of leave, from date, to date, from time, to time

    2. cal From - End Date Time of choosing by input

    3. when I choose Person picker, find history of leave and show in form for see I used leave

     

     Now I do (1), (2)  but can't (3)

     Please suggest me to do !!

     

    Thanks

    Mink

  • 12-27-2010 08:19 PM In reply to

    Re: I would like to create form absence leave ,, please suggest

    Hi Mink,

    So, you want to choose someone and see previous Absence Request history including a subtotal of hours taken?

    If all of the data for all of the people is loaded in your form, you could do this with simple filtering (no code required).

    However, this would be bad because a) the data is static, it doesn't refresh if others are filling out the form from a separate InfoPath instance, and b) the amount of data will be large and inefficient to download and filter all in one form.

    My recommendation would be to promote the fields for Person's name, Date From and Total Hours to your SharePoint form library and then use a filter on this. If you don't have many people, you can filter it in the form, but as I said in (b) above, it's not ideal for large sets of data. If you have >100 absence requests/year I recommend using qRules to pass a field parameter to FilterOwssvr function on SharePoint. SharePoint will filter the list for you on the server and send you back just the items that match. Then, it will be faster.

    Another option is to map your absence requests to a database. We've done a handful of Absence Requests in the past couple years and we tend to use SharePoint list or database to store the data.

    Good luck!

    Patrick Halstead
    Project Manager at Qdabra
  • 12-28-2010 06:57 PM In reply to

    Re: I would like to create form absence leave ,, please suggest

    Hi,

    Now, I cancel to do leave history in form. ^__^

    But I have some question about

    I create 'AbsenceRequest' database and 2 tables for keep my data

       - AbsenceLeave

       - HolidayDate

     

    I can insert all field (Firstname, Lastname, From Date, To Date, Total, Manager, etc.) in form to my database that not database for sharepoint, Right?

    Now, I create infopath in easy type that keep in sharepointlibrary, so I don't know table of database for sharepointlibrary


  • 12-29-2010 06:14 AM In reply to

    Re: I would like to create form absence leave ,, please suggest

    Hi again,

    You can use the SQL Express database that comes with MOSS (SharePoint) but it's not easy and there are licensing restrictions.

    To submit your InfoPath form data to SQL you should either a) design your form from a database before publishing, or b) use a Web service to connect to a DB and submit the data. The latter (b) is the best practice because it provides an abstraction layer between the client and the server which gives you greater flexibility when you have to change the form or the database in the future (since this 'layer' can map from XML to SQL). There are many other good reasons to use a Web service. The main disadvantage is creating one, but Qdabra (sponsor of this site) provides a free trial of a data-driven one that is inexpensive and easy to configure.

    With SharePoint, you can also try a third option: c) submit data to a SharePoint list or library and have the list/library connect to SQL. This approach uses BDC (MOSS 2007) or BCS (ShP 2010) to do the mapping. The approach is not easy and doesn't scale well, but it is possible to do this. However, we recommend Web services and we have lots of experience with all three approaches. Web services is lowest cost long term and least amount of work up front.

     

    Patrick Halstead
    Project Manager at Qdabra
Page 1 of 1 (4 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.