Results 1 to 3 of 3

Thread: Using DataBind with Spring.NET in Visual Studio

  1. #1
    Join Date
    Mar 2011
    Posts
    2

    Default Using DataBind with Spring.NET in Visual Studio

    Hello, I work in a web application that must use Spring.Net. The model of the project works with entities, but we want to use Spring to avoid situations such as:

    Entity.property = TextBox.Text;

    The project also has layers like DAO which makes direct access to the database, facades that make the bridge between the Web page code and services, and services that make the connection between the facade and DAO

    I would like to help me understand how I can use the controls of Spring in a model like this. I'm trying to learn why I joined recently in Spring.Net project.

  2. #2
    Mark Pollack is offline Spring.NET Co-Lead Spring TeamSpring User
    Join Date
    Sep 2004
    Location
    New York, NY
    Posts
    1,683

    Default

    Hi,

    Have you looked into the documentation on the Spring.NET web framework?

    http://www.springframework.net/doc-l.../html/web.html

    Specifically, for the type of situation you talk about,

    Entity.property = TextBox.Text;

    there is a binding feature of the framework that lets you declaratively configure this databinding so that it works both from the controls into your entity and then after your entity comes out of a service layer, binds back from the entity to the controls. More information is available here

    http://www.springframework.net/doc-l...eb-databinding

    There is also a couple of example applications to get you started. The examples that cover individual features of the spring.net web framework are in the installation directory

    <spring-install-dir>\examples\Spring\Spring.WebQuickStart

    There you can find examples on dependency injection for web forms and controls, data binding, page flow, etc. The documention inside the solution and web application itself can help guide you through the functionality.

    For a more complete example, look at the SpringAir example application. That is documented here

    http://www.springframework.net/doc-l...springair.html

    and covers a wide range of features including how to integrate your service and DAO layers.

    Hope this helps.

    Mark

  3. #3
    Join Date
    Mar 2011
    Posts
    2

    Unhappy It don't works!

    I've implemented the methods of Spring.Web.UI.Page, like the InitializeDataBindings, SaveModel, loadModel and so on. I mentioned the control of the spring on the page, and put the property BindingTarget fields. But when I save, the fields are not filled, any idea what could be?

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •