Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Daniel Dawson 27 posts 47 karma points
    Jul 05, 2011 @ 02:00
    Daniel Dawson
    0

    How to create a custom data type for inserting information from a text box into a specific database table

    Hi guys,

    Here's my situation. I have a table in my Umbraco database called 'Player_Bio' with the following fields: Player ID, Player FName, Player LName and other fields for information about the player.

    I'd like in the backend of umbraco to have a text box for each of these fields (except for PlayerID) and be able to have a save and delete button. I've gone to nibble.be and searched every where as to how I could achieve this but I've had no luck.

    I'm good with ASP.Net and C# but implementing it into an Umbraco custom data type is new to me so apologies if this question sounds really easy. On Tim's blog I read something about the user control wrapper and data editor settings.. Is this the best method for creating custom datatypes or am I completely wrong?

    Thanks for your help,

    Dan

  • Nigel Wilson 945 posts 2077 karma points
    Jul 05, 2011 @ 02:25
    Nigel Wilson
    0

    Hi Daniel

    Are the players loaded as members within the site or are they just profiles ?

    If members then you could extend the members area by adding custom properties to store this data.

    If they are not members then why not create a suitable document type and import the data from your custom table to the document type. There is a package that enables data to be imported in bulk -  http://our.umbraco.org/projects/developer-tools/cmsimport

    Hope this helps

    Cheers

    Nigel

     

  • Richard Soeteman 4049 posts 12922 karma points MVP 2x
    Jul 05, 2011 @ 08:33
    Richard Soeteman
    0

    Hi Dan,

    Did you find this article on the Nibble.Be blog? http://www.nibble.be/?p=24

    This is a simple implementation of the usercontrolwrapper, you can customize that to your needs basically all you need to do is implement the value property to  read/write from the database.

    Cheers,

    Richard

  • Daniel Dawson 27 posts 47 karma points
    Jul 05, 2011 @ 13:37
    Daniel Dawson
    0

    Thanks a lot for the replies. 

    Nigel - No they're not members they're just site profiles so I'll have a look at the CMS Import you suggested.

    Richard - I'm going to try the method shown on the article on the nibble blog and see how that goes too.

Please Sign in or register to post replies

Write your reply to:

Draft