Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4255994
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T05:17:35+00:00 2026-05-21T05:17:35+00:00

Having just managed to score a copy of CodeSmith 5.2 at the same time

  • 0

Having just managed to score a copy of CodeSmith 5.2 at the same time that I’m starting on a web development project in ASP.NET I thought I would combine the two.

The site will need to make use of JSON based elements (either jQuery or ExtJS, haven’t decided yet) for search/dropdown type behaviour.

I’ve done a bit of reading, and I see some common issues with JSON serialisation in netTiers regarding circular references, etc.

So it seems I’ve got a choice of netTiers, CSLA, NHibernate, KineticFramework or PLINQO by default.

I’ve used netTiers before.

What I would like is some pointers:

Which framework is easiest to generate compliant code with, and what tweaks need to be made either to the default settings, or to the templates themselves in order to get it to work.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-21T05:17:36+00:00Added an answer on May 21, 2026 at 5:17 am

    I’ve been using netTiers with ExtJs for some time and it is true that there are issues with circular references while encoding, but we seldom return entire entities and find that returning a subset of the entity data works well. We use C#; here’s an example:

    UserAccountService uaSvc = new UserAccountService();
    UserAccount ua = uaSvc.GetByUserId(UserId)[0];
    return Json(new { success = true, data = new { ua.UserName, ua.CustomerName, ua.Email } });
    

    Where the UserAccountService and UserAccount are a service and entity generated using the CodeSmith netTiers templates and the Json() return function is part of Microsoft’s MVC. You can substitute another encoder such as the Newtonsoft one if you’re not using MVC.

    This returns JSON which looks like this; Ext.js can easily consume this:

    {"success": true, data:{"UserName":"Knight", "CustomerName":"Knight Inc.", "Email":"knight@knightknight.com"}}
    

    You can also return a list or array of data, the following uses Linq to acheive it in a very compact way

    return Json(new UserAccountService().GetAll().Select(u=>new  {u.UserID, u.UserName}));
    

    This returns data like this:

    [{"UserName":"Knight", "CustomerName":"Knight Inc.", "Email":"knight@knightknight.com"}, {"UserName":"George", "CustomerName":"George Inc.", "Email":"george@george.com"}]
    

    As you can see, compliant JSON is easy to create from netTiers query results. I haven’t used templates other than the netTiers ones, but I imagine you’d go down a similar avenue.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm having problems with my ASP.NET web forms system. It worked on our test
Having just added a new button in my web application, I get an error
Having just started with MVC 2 I notice that in their starter template they
I've just suffered a horrible time of having my application freezing after a few
I just installed ASP.NET MVC 3 RC to try and upgrade an MVC 2
Having just pulled my hair off because of a difference, I'd like to know
Having just updated Mono to 2.6.3 (on OS X), I noticed in the installer
... after having just read http://www.cocoadev.com/index.pl?CocoaInsecurity ... I am curious to know about your
I'm just having an issue I'm hoping someone will be able to give me
I'm just having a play with Roslyn but unsure on how to do the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.