Skip to main content
deleted 8 characters in body
Source Link
Armali
  • 19.6k
  • 15
  • 64
  • 184

I am new in ssisSSIS. iI am trying to convertingconvert the string into jsonJSON format as shown in the figure. iI install the newtonsoft jsonNewtonsoft Json. But it's showing yellow Triangletriangle mark.

I have install allinstalled all the version of newtonsoft Newtonsoft. But still it's showing the error while #

region Namespaces
using Newtonsoft.Json.Linq;
using System;
using System.Windows.Forms;#
endregion

namespace ST_9a0af2e4537b4d26adaef11149343faa {

 public partial class ScriptMain: Microsoft.SqlServer.Dts.Tasks.ScriptTask.VSTARTScriptObjectModelBase {



  public void Main() {


   var myJsonString = "{report: {Id: \"aaakkj98898983\"}}";
   MessageBox.Show(myJsonString);

   try {
    // when i add this line to my package then the package is not 
    excuting.if i remove this line then package is excuting.
    JObject.Parse("{report: {\"Id\": \"aaakkj98898983\"}}");
   } catch (Exception e) {
    MessageBox.Show(e.ToString());
   }




   Dts.TaskResult = (int) ScriptResults.Success;
  }

 }
}

the script task. My IdeIDE version is visual studioVisual Studio 2015 professionalProfessional.

afterAfter installing the newtonsoftNewtonsoft does not showingshow. when iWhen I close the script task popup and again open the script task edittoreditor, it showing the yellow exclamation mark, and when iI select the newtonsoftNewtonsoft package and check the properties it path & version is showing 0.0.0.0  . then iThen I downloaded the newtonsoftNewtonsoft package and reference the newtonsoft.json.dll file add reference  . thenThen it showing the path and version.

But when iI run the package it showing the error  .

iI have tryiedtried by fllowingfollowing the article also, but didn't gotget success.

Convert JSON String to JSON Object c# https://www.c-sharpcorner.com/article/json-serialization-and-deserialization-in-c-sharp/ https://www.newtonsoft.com/json/help/html/M_Newtonsoft_Json_Linq_JObject_Parse.htm https://www.nuget.org/packages/System.Json/ How to parse JSON without JSON.NET library? Json does not exist in the namespace System Parse JSON string using C# script in SSIS https://learn.microsoft.com/en-us/nuget/quickstart/install-and-use-a-package-in-visual-studio https://www.dotnetjalps.com/2014/04/converting-csharp-object-json-string.html Cannot find JavaScriptSerializer in .Net 4.0

https://riptutorial.com/json-net/topic/1861/getting-started-with-json-net http://www.rockprogrammer.com/2017/08/how-to-install-json-.net-in-visual-studio-2015.htmls

Can one help me to solve this problem.?

Thanks 
Shiv roy

I am new in ssis. i am trying to converting the string into json format as shown in the figure. i install the newtonsoft json. But it's showing yellow Triangle mark.

I have install all the version of newtonsoft . But still it's showing the error while #

region Namespaces
using Newtonsoft.Json.Linq;
using System;
using System.Windows.Forms;#
endregion

namespace ST_9a0af2e4537b4d26adaef11149343faa {

 public partial class ScriptMain: Microsoft.SqlServer.Dts.Tasks.ScriptTask.VSTARTScriptObjectModelBase {



  public void Main() {


   var myJsonString = "{report: {Id: \"aaakkj98898983\"}}";
   MessageBox.Show(myJsonString);

   try {
    // when i add this line to my package then the package is not 
    excuting.if i remove this line then package is excuting.
    JObject.Parse("{report: {\"Id\": \"aaakkj98898983\"}}");
   } catch (Exception e) {
    MessageBox.Show(e.ToString());
   }




   Dts.TaskResult = (int) ScriptResults.Success;
  }

 }
}

the script task. My Ide version is visual studio 2015 professional.

after installing the newtonsoft does not showing. when i close the script task popup and again open the script task edittor it showing the yellow exclamation mark and when i select the newtonsoft package and check the properties it path & version is showing 0.0.0.0  . then i downloaded the newtonsoft package and reference the newtonsoft.json.dll file add reference  . then it showing the path and version.

But when i run the package it showing the error  .

i have tryied by fllowing the article also but didn't got success.

Convert JSON String to JSON Object c# https://www.c-sharpcorner.com/article/json-serialization-and-deserialization-in-c-sharp/ https://www.newtonsoft.com/json/help/html/M_Newtonsoft_Json_Linq_JObject_Parse.htm https://www.nuget.org/packages/System.Json/ How to parse JSON without JSON.NET library? Json does not exist in the namespace System Parse JSON string using C# script in SSIS https://learn.microsoft.com/en-us/nuget/quickstart/install-and-use-a-package-in-visual-studio https://www.dotnetjalps.com/2014/04/converting-csharp-object-json-string.html Cannot find JavaScriptSerializer in .Net 4.0

https://riptutorial.com/json-net/topic/1861/getting-started-with-json-net http://www.rockprogrammer.com/2017/08/how-to-install-json-.net-in-visual-studio-2015.htmls

Can one help me to solve this problem.

Thanks Shiv roy

I am new in SSIS. I am trying to convert the string into JSON format as shown in the figure. I install the Newtonsoft Json. But it's showing yellow triangle mark.

I have installed all the version of Newtonsoft. But still it's showing the error while #

region Namespaces
using Newtonsoft.Json.Linq;
using System;
using System.Windows.Forms;#
endregion

namespace ST_9a0af2e4537b4d26adaef11149343faa {

 public partial class ScriptMain: Microsoft.SqlServer.Dts.Tasks.ScriptTask.VSTARTScriptObjectModelBase {



  public void Main() {


   var myJsonString = "{report: {Id: \"aaakkj98898983\"}}";
   MessageBox.Show(myJsonString);

   try {
    // when i add this line to my package then the package is not 
    excuting.if i remove this line then package is excuting.
    JObject.Parse("{report: {\"Id\": \"aaakkj98898983\"}}");
   } catch (Exception e) {
    MessageBox.Show(e.ToString());
   }




   Dts.TaskResult = (int) ScriptResults.Success;
  }

 }
}

the script task. My IDE version is Visual Studio 2015 Professional.

After installing the Newtonsoft does not show. When I close the script task popup and again open the script task editor, it showing the yellow exclamation mark, and when I select the Newtonsoft package and check the properties it path & version is showing 0.0.0.0. Then I downloaded the Newtonsoft package and reference the newtonsoft.json.dll file add reference. Then it showing the path and version.

But when I run the package it showing the error.

I have tried by following the article also, but didn't get success.

Convert JSON String to JSON Object c# https://www.c-sharpcorner.com/article/json-serialization-and-deserialization-in-c-sharp/ https://www.newtonsoft.com/json/help/html/M_Newtonsoft_Json_Linq_JObject_Parse.htm https://www.nuget.org/packages/System.Json/ How to parse JSON without JSON.NET library? Json does not exist in the namespace System Parse JSON string using C# script in SSIS https://learn.microsoft.com/en-us/nuget/quickstart/install-and-use-a-package-in-visual-studio https://www.dotnetjalps.com/2014/04/converting-csharp-object-json-string.html Cannot find JavaScriptSerializer in .Net 4.0

https://riptutorial.com/json-net/topic/1861/getting-started-with-json-net http://www.rockprogrammer.com/2017/08/how-to-install-json-.net-in-visual-studio-2015.htmls

Can one help me to solve this problem?

Thanks 
Shiv roy

Source Link
shiv roy
  • 11
  • 1
  • 3

convert string to json format in C# . Newtonsoft.json showing yellow mark

I am new in ssis. i am trying to converting the string into json format as shown in the figure. i install the newtonsoft json. But it's showing yellow Triangle mark.

I have install all the version of newtonsoft . But still it's showing the error while #

region Namespaces
using Newtonsoft.Json.Linq;
using System;
using System.Windows.Forms;#
endregion

namespace ST_9a0af2e4537b4d26adaef11149343faa {

 public partial class ScriptMain: Microsoft.SqlServer.Dts.Tasks.ScriptTask.VSTARTScriptObjectModelBase {



  public void Main() {


   var myJsonString = "{report: {Id: \"aaakkj98898983\"}}";
   MessageBox.Show(myJsonString);

   try {
    // when i add this line to my package then the package is not 
    excuting.if i remove this line then package is excuting.
    JObject.Parse("{report: {\"Id\": \"aaakkj98898983\"}}");
   } catch (Exception e) {
    MessageBox.Show(e.ToString());
   }




   Dts.TaskResult = (int) ScriptResults.Success;
  }

 }
}

the script task. My Ide version is visual studio 2015 professional.

after installing the newtonsoft does not showing. when i close the script task popup and again open the script task edittor it showing the yellow exclamation mark and when i select the newtonsoft package and check the properties it path & version is showing 0.0.0.0 . then i downloaded the newtonsoft package and reference the newtonsoft.json.dll file add reference . then it showing the path and version.

But when i run the package it showing the error .

i have tryied by fllowing the article also but didn't got success.

Convert JSON String to JSON Object c# https://www.c-sharpcorner.com/article/json-serialization-and-deserialization-in-c-sharp/ https://www.newtonsoft.com/json/help/html/M_Newtonsoft_Json_Linq_JObject_Parse.htm https://www.nuget.org/packages/System.Json/ How to parse JSON without JSON.NET library? Json does not exist in the namespace System Parse JSON string using C# script in SSIS https://learn.microsoft.com/en-us/nuget/quickstart/install-and-use-a-package-in-visual-studio https://www.dotnetjalps.com/2014/04/converting-csharp-object-json-string.html Cannot find JavaScriptSerializer in .Net 4.0

https://riptutorial.com/json-net/topic/1861/getting-started-with-json-net http://www.rockprogrammer.com/2017/08/how-to-install-json-.net-in-visual-studio-2015.htmls

Can one help me to solve this problem.

Thanks Shiv roy