Copied to clipboard

Flag this post as spam?

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


  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 11, 2011 @ 12:48
    Fuji Kusaka
    0

    How to add a Label in Contour

    Is it possible to add a Label in Contour just a text in between two textField?

     

  • Tom Fulton 2030 posts 4998 karma points c-trib
    Oct 11, 2011 @ 13:55
    Tom Fulton
    0

    Hi Fuji,

    I created a Label fieldtype that you can use to add a row of text, and choose whether or not to show the label's caption.  It's in the latest changeset of Contour Contrib, but hasn't been packaged up yet, so for now you'd need to build the source and copy the DLL to your /bin/

    -Tom

  • lucky 2 posts 22 karma points
    Jun 22, 2015 @ 12:31
    lucky
    0

    Hi Fuji,

    Can you please send the dll for me.

    Thanks in advance

  • lucky 2 posts 22 karma points
    Jun 22, 2015 @ 12:49
    lucky
    0

    Hi Tom,

    Can you please send the dll for me.

    Thanks in advance

  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 11, 2011 @ 15:00
    Fuji Kusaka
    0

    Hi Tom,

    Thanks for the suggestion. But one question, how do you get  a prevalue Label to display in contour? Lets say i create a prevalue just like i would do when connection to db, but this time i use dataType label?

     

  • Tom Fulton 2030 posts 4998 karma points c-trib
    Oct 11, 2011 @ 17:03
    Tom Fulton
    0

    Hey Fuji,

    Not sure what you mean by a prevalue Label.  Here is what the settings for the Label fieldtype look like:

    You can use tokens to pass in special items to the TextToShow box instead of hardcoding it - this might be what you're after?:

    -- [#propertyAlias] (field from current page)
    -- [$propertyAlias] (recursive field)
    -- [%keyName] (Session value)
    -- [@keyName] (Value from request collection [querystring])
    -- [^keyName] (Value from dictionary key)

    -Tom

  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 11, 2011 @ 19:42
    Fuji Kusaka
    0

    Hi Tom,

    This is exactly what am looking for, how to i get to add it in contour?

    What i was talking about earlier, was i tried to create a new Prevalue Source In Contour and gave it a type Label but somehow i think this doesnt do the job right?

    //fuji

  • Tom Fulton 2030 posts 4998 karma points c-trib
    Oct 11, 2011 @ 19:44
    Tom Fulton
    0

    Since it's not packaged yet, you just need to download the source I linked above, compile it, and copy the .DLL file to your /bin/ folder.  If you don't have VS hit me on twitter and I'll see if I can get you the DLL.

  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 11, 2011 @ 19:45
    Fuji Kusaka
    0

    Sorry for the second post am having some issues with the connection. I will try it first thing tomorrow morning

  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 11, 2011 @ 20:02
    Fuji Kusaka
    0

    Just downloaded contourcontrib-7472.zip file, unfortunately i dont have VS on this machine.

  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 12, 2011 @ 07:52
    Fuji Kusaka
    0

    Hey Tom,

    I did Build the Solution then added the dll to the bin folder and added the addkey to web.config.

    <add key="contourContribUseSsl" value="false" /> 

    But when i add a new field and cant see any of the Label Type from the drop down. Am i missing something here?


  • Tom Fulton 2030 posts 4998 karma points c-trib
    Oct 12, 2011 @ 18:45
    Tom Fulton
    0

    Sorry, somehow the new fieldtype wasn't actually added to the solution, if you re-download it should work now.

  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 12, 2011 @ 18:49
    Fuji Kusaka
    0

    Ok let me try it over again..

  • Tom Fulton 2030 posts 4998 karma points c-trib
    Oct 12, 2011 @ 18:50
    Tom Fulton
    1

    I emailed you the DLL, so you can just drop that over your existing one and it should work.

  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 12, 2011 @ 19:27
    Fuji Kusaka
    0

    Got it working Tom, Thanks for the help.

     

    //fuji

  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 12, 2011 @ 19:52
    Fuji Kusaka
    0

    Tom am having a weird issue here, i just lost all the data i am pulling from my db when using the Prevalue Sources.

  • Tom Fulton 2030 posts 4998 karma points c-trib
    Oct 12, 2011 @ 19:55
    Tom Fulton
    0

    This fieldtype shouldn't affect that, it doesn't use prevalue sorces.

    But I have heard of a similar bug in Contour, see this thread..don't really know much about it though:  BUG - Pre Value Datasoruces From Datatypes Getting Deleted From DB

  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 12, 2011 @ 20:06
    Fuji Kusaka
    0

    Damn, i just read this thread and its really annoying since am using the prevalue sources to display a list of countries and just bought the licence version of Contour 1.1.9 and have like 4 different forms with a drop down Country list.

  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 14, 2011 @ 14:56
    Fuji Kusaka
    0

    Hey Tom,

    I just happened to make a test with the Label Type on Contour v 1.1.9 and when Submitting the form am getting a Server Error. I also added to my web.config

    <add key="contourContribUseSsl" value="false" />

     

    Server Error in '/' Application.


    Object reference not set to an instance of an object.

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

    Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

    Source Error: 

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.


    Stack Trace: 

    [NullReferenceException: Object reference not set to an instance of an object.]
       Umbraco.Forms.Data.Storage.RecordFieldValueStorage.InsertRecordFieldValues(RecordField rf) +677
       Umbraco.Forms.Data.Storage.RecordFieldStorage.InsertRecordField(RecordField recordfield) +1196
       Umbraco.Forms.Data.Storage.RecordStorage.InsertRecord(Record record, Form form) +1865
       Umbraco.Forms.Core.Services.RecordService.‘() +205
       Umbraco.Forms.Core.Services.RecordService.Submit() +39
       Umbraco.Forms.Core.Services.RecordService.NextPage() +169
       Umbraco.Forms.UI.Usercontrols.RenderForm.nextPage(Object sender, EventArgs e) +241
       System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +153
       System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3706
    



    Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.1

    Any Suggestion to this?... I made a checked and removed the Label and it works well..

  • Tom Fulton 2030 posts 4998 karma points c-trib
    Oct 14, 2011 @ 16:15
    Tom Fulton
    0

    Sorry, should be fixed in the latest changeset

  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 14, 2011 @ 16:35
    Fuji Kusaka
    0

    Yes its working with the new dll. Thanks

  • Phillip Ng 148 posts 250 karma points
    Jan 27, 2012 @ 05:04
    Phillip Ng
    0

    It's probably a PEBKAC error, but this isn't working. I navigated to http://our.umbraco.org/projects/developer-tools/contour-contrib and found the Contour.Contrib.dll. That was dropped into the bin folder of my website and added <addkey="contourContribUseSsl"value="false"/> into my web.config file, but I can't create a Label type in Contour. Am I missing something? I've restarted the application without any changes as well. Thanks in advance!

  • Tom Fulton 2030 posts 4998 karma points c-trib
    Jan 27, 2012 @ 05:27
    Tom Fulton
    0

    Hi Phillip,

    What exactly is preventing you from adding the label, does it just not show up in the Field Type dropdown?

    As long as the DLL is in the /bin/ folder it should show up.  Unless maybe you are using the DLL from the package?  The Label fieldtype was added after the last package release so it's never been packaged up on the our page - you'll need to download and compile the Contour Contrib source for the correct DLL.  Or if you don't have VS I could try to send to you?

    -Tom

  • Fuji Kusaka 2203 posts 4220 karma points
    Jan 27, 2012 @ 05:28
    Fuji Kusaka
    0

    Hi Phillip,

    Am not sure you are using the right dll. In your contour design mode do you have the option of adding a Label or can you even see the Icon from the Drop Down with  a Label on it?

    Let me know i can forward you the one i have which works perfectly from Tom.

    //fuji

  • Phillip Ng 148 posts 250 karma points
    Jan 27, 2012 @ 19:10
    Phillip Ng
    0

    Yeah, I am probably using the wrong dll. Fuji or Tom, would you be able to send it to me? I can be reached at phil [at] bonsaimediagroup [dot] com. Thank you!

  • Fuji Kusaka 2203 posts 4220 karma points
    Jan 28, 2012 @ 09:53
    Fuji Kusaka
    0

    Hey Philip, the dll is on its way. Credit to Tom for this.

    //fuji

  • Phillip Ng 148 posts 250 karma points
    Jan 28, 2012 @ 20:43
    Phillip Ng
    0

    Got it and it works! One other thing. When I created a Label field and ran a test submission, in the email, it shows an empty "Label: " line. The "Text To Show" field isn't populated in the email. Is that by default? In case my client asks, is there a way to enable it? Thanks guys!

  • Tom Fulton 2030 posts 4998 karma points c-trib
    Jan 30, 2012 @ 17:05
    Tom Fulton
    1

    Hi Phillip,

    Currently the Label fieldtype doesn't save any data.  When developing it I didn't think it was necessarsy since it was just static text and not any input from the user.  Perhaps I could have it save the content with the form, do you think that would be useful?

    -Tom

  • Phillip Ng 148 posts 250 karma points
    Feb 04, 2012 @ 06:43
    Phillip Ng
    0

    Right, makes sense. I don't think the update is necessary. Thank you!

  • Carl Sargunar 69 posts 91 karma points MVP 3x
    Feb 10, 2012 @ 12:09
    Carl Sargunar
    0

    Hi Guys - this is exactly the piece of functionality I need to add to my forms yet - As it's not in 0.5 of the contrinb package yet - any idea where I can get a hold of this dll? 

     

    Thanks

  • Tom Fulton 2030 posts 4998 karma points c-trib
    Feb 10, 2012 @ 14:08
    Tom Fulton
    0

    Hi Carl,

    If you want to hit me up on twitter I can email it to you for now.  I will try to nudge Sebastiaan to see if we can package up and release a new version of Contour Contrib shortly :)

    -Tom

  • Phillip Ng 148 posts 250 karma points
    May 02, 2012 @ 20:38
    Phillip Ng
    0

    Hey guys

    I'm having trouble implementing labels in 4.7.1. When I add a label and preview the form, a "string was not recognized as a valid boolean" error is thrown. When the label is removed, the preview works okay. Do you have any suggestions or advice? Thank you!

  • Phillip Ng 148 posts 250 karma points
    May 08, 2012 @ 01:27
    Phillip Ng
    0

    Bump. Anybody?

  • Tom Fulton 2030 posts 4998 karma points c-trib
    May 09, 2012 @ 14:52
    Tom Fulton
    0

    Hi Phillip,

    I think there were some changes in a later Contour version that broke this.  The error is with the bool.parse line for the FieldSetting - if you just change that to true/false for now or do a proper check you can make it work.  I'll post a fix shortly.

    -Tom

  • Phillip Ng 148 posts 250 karma points
    May 09, 2012 @ 20:47
    Phillip Ng
    0

    Is that in the database?

  • Tom Fulton 2030 posts 4998 karma points c-trib
    May 09, 2012 @ 21:44
    Tom Fulton
    0

    No, it's in the code of Label.cs

  • Phillip Ng 148 posts 250 karma points
    May 22, 2012 @ 21:05
    Phillip Ng
    0

    Is Label.cs in Codeplex? Thanks!

  • Phillip Ng 148 posts 250 karma points
    Jun 08, 2012 @ 20:49
    Phillip Ng
    0

    I found Label.cs in the Contour Contrib codeplex but can't find the line you were referring to. Can you provide some additional assistance? Thanks!

  • Johnny Thrash 1 post 21 karma points
    Jul 09, 2012 @ 16:46
    Johnny Thrash
    0

    That line isn't in the Label.cs file I have (downloaded directly from codeplex).  I've also looked through my C# books, MSDN and googled and am unable to find a reference for inserting/using bool.parse.  I have got to be able to add these labels to my forms or Contour is absolutely useless to me.  I would greatly appreciate any assistance with the boolean error that has already been reported.

    Thanks so much!

  • Warren 12 posts 41 karma points
    Aug 14, 2012 @ 11:07
    Warren
    0

    if you could hit me up with the .dll to add a label to the available fields it would be appreciated, i have downloaded the Contour.Contrib.dll and added the <add key="contourContribUseSsl" value="false"/> key to the web.config but still no label in the drop down list of available fields, am i missing something ?

    many thanks in advance

    W

  • Ruald Gerber 20 posts 41 karma points
    Oct 02, 2012 @ 17:29
    Ruald Gerber
    0

    Hi

    I added the Label.cs directly into my VS project and then built it and everything seems to work (On 4.7.2 and 4.8.1). Hope this helps someone.

    P.S. Hope this doesnt violate any licence.

     

  • Robbie van den Hoven 36 posts 181 karma points
    Oct 23, 2012 @ 14:49
    Robbie van den Hoven
    0

    Hi there, I also want to use a label field in contour.

    So I downloaded the zip (contourcontrib-7472.zip) , build it in visual studio en then copied (overwrite) the file 'Contour.Contrib.dll' form 'contourcontrib-7472\Contour.Contrib\Release\bin' to the '\bin\' folder of my Umbraco site.
    I restarted my site, but can't see the 'Label' type in the dropdown. The captcha type of 'Contour contrib' is visible, so 'Contour contrib' is installed correctly.

    Any idea what I do wrong?

     

Please Sign in or register to post replies

Write your reply to:

Draft