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?
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
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.
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
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
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
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.
is working on a reply...