Quantcast
Channel: SCN : All Content - ABAP Development
Viewing all articles
Browse latest Browse all 8332

How to format XML tags in lean manner

$
0
0

Hi,

 

I have the XML file like unformatted need to format it in ABAP, please suggest me some examples ?

 

Unformatted:

 

<?xml version="1.0" encoding="utf-8"?><Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"><PropertyGroup><SchemaVersion>2.0</SchemaVersion><ProjectGuid>{00163e06-2091-1ee4-8399-32cf04305b1f}</ProjectGuid><ProjectType>CopernicusProject</ProjectType><Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration><Name>YCNBE4GCY</Name><RootNamespace>YCNBE4GCY</RootNamespace><RepositoryNamespace>http://463558-one-off.sap.com/YCNBE4GCY_</RepositoryNamespace><RuntimeNamespacePrefix>YCNBE4GCY_</RuntimeNamespacePrefix><RepositoryRootFolder>/YCNBE4GCY_MAIN</RepositoryRootFolder><DefaultProcessComponent>YCNBE4GCY_YCNBE4GCY</DefaultProcessComponent><DevelopmentPackage>$YCNBE4GCY_DEV</DevelopmentPackage><XRepSolution>YCNBE4GCY_MAIN</XRepSolution><BCSourceFolderInXRep>/YCNBE4GCY_BC/SRC</BCSourceFolderInXRep><ProjectSourceFolderinXRep>/YCNBE4GCY_MAIN/SRC</ProjectSourceFolderinXRep><DeploymentUnit>CUSTOMER_RELATIONSHIP_MGMT</DeploymentUnit><CompilerVersion>1302_FP15</CompilerVersion></PropertyGroup><PropertyGroup Condition=" '$(Configuration)' == 'Debug' "><OutputPath>bin</OutputPath></PropertyGroup><ItemGroup/><ItemGroup/><ItemGroup/><Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets"/></Project>

 

 

I want to format it like below :

 

Formatted:

 

<?xml version="1.0" encoding="utf-8" ?>

<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

<PropertyGroup>

<SchemaVersion>2.0</SchemaVersion>

  <ProjectGuid>{00163e06-2091-1ee4-8399-32cf04305b1f}</ProjectGuid>

  <ProjectType>CopernicusProject</ProjectType>

  <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>

  <Name>Y5CMK5NHY</Name>

  <RootNamespace>Y5CMK5NHY</RootNamespace>

  <RepositoryNamespace>http://463558-one-off.sap.com/Y5CMK5NHY_</RepositoryNamespace>

  <RuntimeNamespacePrefix>Y5CMK5NHY_</RuntimeNamespacePrefix>

  <RepositoryRootFolder>/Y5CMK5NHY_MAIN</RepositoryRootFolder>

  <DefaultProcessComponent>Y5CMK5NHY_Y5CMK5NHY</DefaultProcessComponent>

  <DevelopmentPackage>$Y5CMK5NHY_DEV</DevelopmentPackage>

  <XRepSolution>Y5CMK5NHY_MAIN</XRepSolution>

  <BCSourceFolderInXRep>/Y5CMK5NHY_BC/SRC</BCSourceFolderInXRep>

  <ProjectSourceFolderinXRep>/Y5CMK5NHY_MAIN/SRC</ProjectSourceFolderinXRep>

  <DeploymentUnit>CUSTOMER_RELATIONSHIP_MGMT</DeploymentUnit>

  <CompilerVersion>1302_FP15</CompilerVersion>

  </PropertyGroup>

<PropertyGroup Condition=" '$(Configuration)' == 'Debug' ">

<OutputPath>bin</OutputPath>

  </PropertyGroup>

  <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets"/>

    </Project>


Thanks in advance.


Best Regards, Prabhu


Viewing all articles
Browse latest Browse all 8332

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>