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 8305727
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T18:10:53+00:00 2026-06-08T18:10:53+00:00

Im currently trying to filter some information from a file we have coming to

  • 0

Im currently trying to filter some information from a file we have coming to our application from a web server

the format the information is currently in is :

{"ns2":"ns2.xxxx.xxx","ns1":"ns1.xxxx.xxx","classname":"com.logicboxes.foundation.sfnb.order.domorder.DomCno","privacyprotectedallowed":"true","isOrderSuspendedUponExpiry":"false","noOfNameServers":"2","isprivacyprotected":"true","classkey":"domcno","isImmediateReseller":"false"}

What we would like to do is extract the information piece by piece but we are trying to start with the NS2 and NS1 fields

Before we had the following to format our data but i couldnt seem to change it around to make it filter out the above string

Dim m As New Regex("(?<=<div id=""xxxx"">).+(?=</div>)")

I was wondering if someone here could give me a path to go down

Thanks

  • 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-06-08T18:10:54+00:00Added an answer on June 8, 2026 at 6:10 pm

    In your case, you can do something like this:

    Your JSON result as a .net object

    string json = "{"ns2":"ns2.xxxx.xxx","ns1":"ns1.xxxx.xxx","classname":"com.logicboxes.foundation.sfnb.order.domorder.DomCno","privacyprotectedallowed":"true","isOrderSuspendedUponExpiry":"false","noOfNameServers":"2","isprivacyprotected":"true","classkey":"domcno","isImmediateReseller":"false"}";
    
    
    public class Blob
    {
          public string ns2 {get;set;}
          public string ns1 {get;set;}
          public string classname {get;set;}
          public bool privacyprotectedallowed {get;set;}
          public bool isOrderSuspendedUponExpiry{get;set;}
          public int noOfNameServers{get;set;}
          public bool isprivacyprotected{get;set;}
          public string classkey{get;set;}
          public bool isImmediateReseller{get;set;}
    }
    

    You can use this library to convert it: http://james.newtonking.com/projects/json-net.aspx

    Here’s the example:

    var Blob = JsonConvert.DeserializeObject<Blob>(json);
    

    Hope this helps you out!

    I would also recommend to take a look at the ContractResolvers, so you can use PascalCasing for your properties. More info can be found here

    If you don’t want to create the Blob object, you can also try this:

    JObject obj = JObject.Parse(json);
    string ns1 = (string)obj["ns1"];
    string ns2 = (string)obj["ns2"];
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Im currently trying to downlaod a audio track from a WCF, i need some
I'm trying to make a loading overlay thing. Currently, I have some javascript adding
ES 2.0 newbie here. I'm currently trying to make some 3D interlaced images from
I'm starting with yii and I have some trouble when trying to filter an
I am currently trying to create a site that filter the content based on
im trying to create an image filter in OpenGL CE. currently I am trying
Im currently trying to learn some stuff about encryption, it's algorithms and how it
I am currently trying to write some code that will accept some FTP details,
I have developed a blog application of sorts that I am trying to allow
I'm new to Django, trying to process some forms. I have this form for

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.