<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-5609619104114830730</id><updated>2024-08-30T05:57:46.543-07:00</updated><title type='text'>Tricks and tips in .net with easy codes</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default?start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>39</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-7407633895624796386</id><published>2012-07-29T01:20:00.001-07:00</published><updated>2012-07-29T01:20:51.560-07:00</updated><title type='text'>Simple version control using TortoiseSVN 1.7.7 Part 2</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;u&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&amp;nbsp;Procedure 2 :&lt;/span&gt;&lt;/b&gt;&lt;/u&gt;&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;I guess you have read the first part : if not then for reference the link is :&lt;br /&gt;
&lt;a href=&quot;http://mynecessarycode.blogspot.in/2012/07/simple-version-control-using.html&quot; target=&quot;_blank&quot;&gt;Simple Version Control Using Tortoise SVN 1.7.7 Part 1&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
I have a project folder called &lt;b&gt;Folder Locker&lt;/b&gt; somewhere in my hard disk which i want to control using SVN . For the viewing benefit i have put it inside the same directory but you can put them any different directories .&lt;br /&gt;
Now i will create a working repository for my project which by the way mean check out an d we will simply put a copy of our project or the main project itself into the working repository .For this I have created a folder &lt;b&gt;&quot;Sub Version Repo&quot;&lt;/b&gt; and it looks like this .&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgxpWQiYRo2VQlzgoKPgzOy8JE7dn7XVg89-FwM-HdrtuJEVhClkR9axbxsm6tGQWcq7qRklQF12qxH6kDEOlP-efF0kv3FymJq5n1TmMmDdgLKQGpd9xwQHXOSf065qgPC9O7V-REVVJgP/s1600/7.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;236&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgxpWQiYRo2VQlzgoKPgzOy8JE7dn7XVg89-FwM-HdrtuJEVhClkR9axbxsm6tGQWcq7qRklQF12qxH6kDEOlP-efF0kv3FymJq5n1TmMmDdgLKQGpd9xwQHXOSf065qgPC9O7V-REVVJgP/s320/7.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
Now we will check out the &lt;b&gt;Repository &lt;/b&gt;into &lt;b&gt;Sub Version Repo &lt;/b&gt;.&lt;br /&gt;
Its simple just right click on &lt;b&gt;Sub Version Repo&lt;/b&gt; and&amp;nbsp; click on &lt;b&gt;SVN Checkout &lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;This window will appear, where &lt;b&gt;URL or repository &lt;/b&gt;has already taken repository path and my created &lt;b&gt;My Project Folder &lt;/b&gt;we can delete the path and browse repository from anywhere . below this containing the sub version repo i.e. the check out directory , No need to change anything right now . Just click OK .&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg02DWvQLL-V42RyzKNNVVbftlaM8fKIkNB8gOILR3EuDpTFI4uvwfg3-gGZ2VOd2i7beaHSY8hKRyCR_Bl1npOWk4YwEe1S5vh-EhQDjyKKYaienWxw6dhFGqYzc4qWQkQRVcnpkpRjlDe/s1600/8.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: right; float: right; margin-bottom: 1em; margin-left: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;262&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg02DWvQLL-V42RyzKNNVVbftlaM8fKIkNB8gOILR3EuDpTFI4uvwfg3-gGZ2VOd2i7beaHSY8hKRyCR_Bl1npOWk4YwEe1S5vh-EhQDjyKKYaienWxw6dhFGqYzc4qWQkQRVcnpkpRjlDe/s320/8.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
It will show Checkout finished got our first revision .&lt;br /&gt;
SVN does this numbering for their tracking purpose.&lt;br /&gt;
You will see a .svn file (if your view hidden files and folder property is set true), never ever delete these files , they are really important .&lt;br /&gt;
&lt;br /&gt;
OK, now we will copy our project file into the&lt;br /&gt;
checked out directory &quot;&lt;b&gt;Sub Version Repo&lt;/b&gt;&quot;&lt;br /&gt;
since they are not still added to our version controller it looks like this :&lt;br /&gt;
&lt;br /&gt;
We need to add it&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEijc3GiJ5kZgmgrzFW-tpv-N4JG6ebirgBAUxJjMH8vmE0ji5MKObN2tN6wkdoo1mS4xMveJfUYnjctsqhNLkqiM2gkV0qCU01nKrKjTQQip1qhmo6TirBWI-j76AkyQOBUICCm_ldST1fq/s1600/9-10.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;130&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEijc3GiJ5kZgmgrzFW-tpv-N4JG6ebirgBAUxJjMH8vmE0ji5MKObN2tN6wkdoo1mS4xMveJfUYnjctsqhNLkqiM2gkV0qCU01nKrKjTQQip1qhmo6TirBWI-j76AkyQOBUICCm_ldST1fq/s400/9-10.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
To add the project we will right click on the sub Version Repo&amp;nbsp; go to&lt;br /&gt;
TortoiseSVN and at the bottom of the ling menu click on Add ,it will show a checked list of all the files and the folders inside the main directory . for the first time click ok .&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgJCL61g7TV8iDILj8B88zQE6hFli34TXzELL1DqzmciClCXulTh3w-oP1AnkWRQncadnYhY3i4uTEMOIqWwvGxUVJPKmUYbPJuws_Lvn3h3R1WtaJDPZ1IS-IvZyEgCP-zRV84etRi0zd3/s1600/12.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: right; float: right; margin-bottom: 1em; margin-left: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;137&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgJCL61g7TV8iDILj8B88zQE6hFli34TXzELL1DqzmciClCXulTh3w-oP1AnkWRQncadnYhY3i4uTEMOIqWwvGxUVJPKmUYbPJuws_Lvn3h3R1WtaJDPZ1IS-IvZyEgCP-zRV84etRi0zd3/s320/12.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
This will add the project to the svn and now we will commit our project to the svn .Right click on the directory and click on svn commit . you will see all the files and folders are with green right arrow .&lt;br /&gt;
So this mean we have got a ready to work , completely version controlled project environment .&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjUlgSH5xlGg-oZGuTy5jJ6v5I7cBqJemknacMfUAmDYZTBhog57GVxNheRmfUFbTy6ojMY85L1HcbXl9JhT0PqnsuM2d2BuQXmKjWKX-trXaS-sImSm3GFC8OUGiz58ZZ2L-0Zn6vUP0hA/s1600/13.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;132&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjUlgSH5xlGg-oZGuTy5jJ6v5I7cBqJemknacMfUAmDYZTBhog57GVxNheRmfUFbTy6ojMY85L1HcbXl9JhT0PqnsuM2d2BuQXmKjWKX-trXaS-sImSm3GFC8OUGiz58ZZ2L-0Zn6vUP0hA/s400/13.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
Now suppose we this workable project folder in another PC connected to the environment with tortoise svn installed . we don&#39;t need to copy and paste all the files . We can create URL of the project like this .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Right click inside the main directory, in the context men go to &lt;b&gt;TortoiseSVN --&amp;gt; Repo browser&lt;/b&gt;&lt;br /&gt;
at the top of the window , int the text box beside the URL you will find the project folder url copy it to the different computer . there create a folder according the relevant name .&lt;br /&gt;
right click inside the directory .. in the context menu go to SVN check out , click it and in the text of URL of repository paste the copied link and click ok , all the project files will be successfully downloaded to the computer .&lt;br /&gt;
&lt;br /&gt;
So that&#39;s for today , in next tutorial we will learn some basic using tips of svn .&lt;br /&gt;
If you find this article helpful please give your precious comment .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/7407633895624796386/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2012/07/simple-version-control-using_29.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/7407633895624796386'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/7407633895624796386'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2012/07/simple-version-control-using_29.html' title='Simple version control using TortoiseSVN 1.7.7 Part 2'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgxpWQiYRo2VQlzgoKPgzOy8JE7dn7XVg89-FwM-HdrtuJEVhClkR9axbxsm6tGQWcq7qRklQF12qxH6kDEOlP-efF0kv3FymJq5n1TmMmDdgLKQGpd9xwQHXOSf065qgPC9O7V-REVVJgP/s72-c/7.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-7401195914429363825</id><published>2012-07-28T22:22:00.000-07:00</published><updated>2012-07-28T22:23:47.593-07:00</updated><title type='text'>Simple version control using TortoiseSVN 1.7.7 Part 1</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;u&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;Prelude :&lt;/span&gt;&lt;/b&gt;&lt;/u&gt; &lt;br /&gt;
In this tutorial i am going to demonstrate how to use a version control . But before that i will ask myself what is version control . There are several perfect definition you can find in the internet .To me its a system that controls the several versions of my project(any document) and by version it means any modification(Add/Modify/Delete) to the document .It is not much of a necessary when you are doing a project alone in your single PC , but in distributed architecture where several people working on a same project its the best possible way&amp;nbsp; to control your project .&lt;br /&gt;
&lt;br /&gt;
For further reference you can visit : &lt;a href=&quot;http://en.wikipedia.org/wiki/Revision_control&quot; target=&quot;_blank&quot;&gt;http://en.wikipedia.org/wiki/Revision_control&lt;/a&gt;&lt;br /&gt;
OK , now this not a theoretical description of version controlling and that is why probably i am writing this article , because when i search internet i just needed a step by step procedure to work on Version Control using the user interface ( not using command line ) for the beginners and i didn&#39;t find any good. So if want more of a theoretical one there are thousand tutorials you can go through.&lt;br /&gt;
&lt;br /&gt;
There are several s/w in market can be used for the system like :&lt;br /&gt;
Visual Source Safe , but in my demonstration i am going to use tortoiseSVN.&lt;br /&gt;
The current version of it is &lt;span style=&quot;color: black; font-size: small;&quot;&gt;&lt;a href=&quot;http://tortoisesvn.net/#&quot;&gt;TortoiseSVN 1.7.7&amp;nbsp;&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: black; font-size: small;&quot;&gt;you can download it from&amp;nbsp;&lt;a href=&quot;http://tortoisesvn.net/downloads.html&quot; target=&quot;_blank&quot;&gt;http://tortoisesvn.net/downloads.html&lt;/a&gt; as it is a open source software according to your OS ( 32 bit / 64 bit ). Its a simple installation . Do it . So our necessary environment is created .&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: black; font-size: small;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: black; font-size: small;&quot;&gt;&lt;u&gt;&lt;b&gt;&lt;span style=&quot;font-size: large;&quot;&gt;Process 1 ( Creating Repository ) :&lt;/span&gt;&lt;/b&gt;&lt;/u&gt;&lt;/span&gt;&lt;br /&gt;
SVN repository is used to manage the files, folders, directories 
and any modifications made to the files, folders and directories .It contains the full history of the particular projects .&lt;br /&gt;
Create a folder on a directory which is always accessible and write permissible . &lt;br /&gt;
lets create C:\My Files\SVN Demonstration\Repository ( Rename it anything )&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg3wF06cuLqpizUMuIuSoPI2GOxxX8zbFD7Ki0jyFGuseWyi7H_rTKpCDMCBfk-cApmg3cQU9fzbQDgwJtkEq6fwwnDconL87sZJuxcjJRbN0NP9SPj4TwuDMTM94EGpOFjRKa5S9jXFXFn/s1600/1.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;142&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg3wF06cuLqpizUMuIuSoPI2GOxxX8zbFD7Ki0jyFGuseWyi7H_rTKpCDMCBfk-cApmg3cQU9fzbQDgwJtkEq6fwwnDconL87sZJuxcjJRbN0NP9SPj4TwuDMTM94EGpOFjRKa5S9jXFXFn/s320/1.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
Its just an empty folder .&lt;br /&gt;
Lets create a repository here .&lt;br /&gt;
Right click on it , in the context menu&amp;nbsp;&lt;b&gt; TortoiseSVN &lt;/b&gt;click on&lt;b&gt; Create Repository&lt;/b&gt; here&amp;nbsp; , a small window will appear&lt;br /&gt;
click on&amp;nbsp; &lt;b&gt;Create folder structure&lt;/b&gt; .&lt;br /&gt;
it will create the folder structure inside repository .&lt;br /&gt;
&lt;br /&gt;
Do not alter any of the files inside the created repository as it is very important .&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj53i4v8lo0Q85WtIe5MDF1ZpC8OmqlIrwwB7wLs4ldnopj6sEVIUgWU8rBqwJrkmM0gzyiNFphyphenhyphenQIDe6ikd5p9xfB1xllypaYDJVmeoxHreSpXO_m8D8Lf7-bC2-0sacK9S4MaDc0Y91HE/s1600/2-3.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: right; float: right; margin-bottom: 1em; margin-left: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;176&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj53i4v8lo0Q85WtIe5MDF1ZpC8OmqlIrwwB7wLs4ldnopj6sEVIUgWU8rBqwJrkmM0gzyiNFphyphenhyphenQIDe6ikd5p9xfB1xllypaYDJVmeoxHreSpXO_m8D8Lf7-bC2-0sacK9S4MaDc0Y91HE/s400/2-3.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
I have a project folder merely small . &lt;br /&gt;
Create a folder for our Project in the newly created repository .&lt;br /&gt;
Right click on the folder &lt;b&gt;Repository --&amp;gt;TortoiseSVN --&amp;gt; Repo-browser&lt;/b&gt;&lt;br /&gt;
and&amp;nbsp; create a folder with relevant name &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhmquwbyNR27xstKQzzlvwgg3ky5LU9hlSvWibmlwG4YEc_SLjZ_t57CLcX4KrRg9Y3VB8Zf9SPjgXNOpiFrCTQaRa0KW0PAOMtC20J7j65e4bBp7KODsV3C4L9LB5wqdKejOxnAKphzgWN/s1600/4-5-6.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;258&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhmquwbyNR27xstKQzzlvwgg3ky5LU9hlSvWibmlwG4YEc_SLjZ_t57CLcX4KrRg9Y3VB8Zf9SPjgXNOpiFrCTQaRa0KW0PAOMtC20J7j65e4bBp7KODsV3C4L9LB5wqdKejOxnAKphzgWN/s640/4-5-6.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
So our repository creation is complete and ready to use . The next part will be on the following link&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/7401195914429363825/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2012/07/simple-version-control-using.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/7401195914429363825'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/7401195914429363825'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2012/07/simple-version-control-using.html' title='Simple version control using TortoiseSVN 1.7.7 Part 1'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg3wF06cuLqpizUMuIuSoPI2GOxxX8zbFD7Ki0jyFGuseWyi7H_rTKpCDMCBfk-cApmg3cQU9fzbQDgwJtkEq6fwwnDconL87sZJuxcjJRbN0NP9SPj4TwuDMTM94EGpOFjRKa5S9jXFXFn/s72-c/1.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-1354197471922627812</id><published>2012-06-20T20:41:00.002-07:00</published><updated>2012-06-21T01:00:17.364-07:00</updated><title type='text'>Merge multiple rows into a single using T-Sql stuff function</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
Some days ago i had a problem that I had a table of schemes they have unique scheme code , and a Manager table that contains all the managers . Multiple managers can be allotted to a scheme as well as a single can be . My requirement was to show all the managers under a scheme in a single row and column&amp;nbsp; separated by comma . I wanted a small query and i was introduced to a new function stuff&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjfWltKMGqklPTem41Dyg_qKfCYu8imgDryBSytFcIhfBnVRuq86iod3K0pTx7k8TVSkxauyNNnGLXeomdqb-3tweAV20Toy5gFIw_0NM5DKhkpBTRyrgQf7Xwv-Q4CpUZQJtKwqGYKzFbz/s1600/stuff.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;400&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjfWltKMGqklPTem41Dyg_qKfCYu8imgDryBSytFcIhfBnVRuq86iod3K0pTx7k8TVSkxauyNNnGLXeomdqb-3tweAV20Toy5gFIw_0NM5DKhkpBTRyrgQf7Xwv-Q4CpUZQJtKwqGYKzFbz/s400/stuff.png&quot; width=&quot;326&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
For detail reference you can go through link :&lt;br /&gt;
&lt;a href=&quot;http://msdn.microsoft.com/en-us/library/ms188043.aspx&quot; target=&quot;_blank&quot;&gt;http://msdn.microsoft.com/en-us/library/ms188043.aspx&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
So here is the example: &lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhq32J0hTEpNWVlr2fy56BGgD4mO1Ye8zYycv_KZmowfNKyxxqf7qzw-Mb46d5egfP7HPKLHyObPIr-8F-v2SEeiSHIDrslgLSnq2caz4y2izYBgZkn7wi8uz5ogsD-69vNrPSjF-hGbCxm/s1600/tab1-tile.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;188&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhq32J0hTEpNWVlr2fy56BGgD4mO1Ye8zYycv_KZmowfNKyxxqf7qzw-Mb46d5egfP7HPKLHyObPIr-8F-v2SEeiSHIDrslgLSnq2caz4y2izYBgZkn7wi8uz5ogsD-69vNrPSjF-hGbCxm/s640/tab1-tile.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
now if I use the simple stuff function ike&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;select&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: magenta;&quot;&gt;STUFF&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;((&lt;/span&gt;&lt;span style=&quot;color: blue;&quot;&gt;SELECT&lt;/span&gt;&amp;nbsp; &lt;span style=&quot;color: red;&quot;&gt;&#39;,&#39;&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;+&lt;/span&gt;FM&lt;span style=&quot;color: grey;&quot;&gt;.&lt;/span&gt;FUND_NAME &lt;span style=&quot;color: blue;&quot;&gt;FROM&lt;/span&gt;
SCH_FUND SF &lt;span style=&quot;color: grey;&quot;&gt;INNER&lt;/span&gt; &lt;span style=&quot;color: grey;&quot;&gt;JOIN&lt;/span&gt;
FUND_MANAGER FM &lt;span style=&quot;color: blue;&quot;&gt;ON&lt;/span&gt; SF&lt;span style=&quot;color: grey;&quot;&gt;.&lt;/span&gt;FUND_CODE&lt;span style=&quot;color: grey;&quot;&gt;=&lt;/span&gt;FM&lt;span style=&quot;color: grey;&quot;&gt;.&lt;/span&gt;FUND_CODE&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;FOR&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;XML&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;PATH&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: red;&quot;&gt;&#39;&#39;&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;))&lt;/span&gt; &lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt; 1 &lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt; 1 &lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt; &lt;span style=&quot;color: red;&quot;&gt;&#39;&#39;&lt;/span&gt; &lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;span style=&quot;color: grey;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;it will result&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;img alt=&quot;&quot; src=&quot;data:image/jpeg;base64,/9j/4AAQSkZJRgABAQEAYABgAAD/2wBDAAoHBwgHBgoICAgLCgoLDhgQDg0NDh0VFhEYIx8lJCIfIiEmKzcvJik0KSEiMEExNDk7Pj4+JS5ESUM8SDc9Pjv/2wBDAQoLCw4NDhwQEBw7KCIoOzs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozv/wAARCABZAcoDASIAAhEBAxEB/8QAHwAAAQUBAQEBAQEAAAAAAAAAAAECAwQFBgcICQoL/8QAtRAAAgEDAwIEAwUFBAQAAAF9AQIDAAQRBRIhMUEGE1FhByJxFDKBkaEII0KxwRVS0fAkM2JyggkKFhcYGRolJicoKSo0NTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqDhIWGh4iJipKTlJWWl5iZmqKjpKWmp6ipqrKztLW2t7i5usLDxMXGx8jJytLT1NXW19jZ2uHi4+Tl5ufo6erx8vP09fb3+Pn6/8QAHwEAAwEBAQEBAQEBAQAAAAAAAAECAwQFBgcICQoL/8QAtREAAgECBAQDBAcFBAQAAQJ3AAECAxEEBSExBhJBUQdhcRMiMoEIFEKRobHBCSMzUvAVYnLRChYkNOEl8RcYGRomJygpKjU2Nzg5OkNERUZHSElKU1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6goOEhYaHiImKkpOUlZaXmJmaoqOkpaanqKmqsrO0tba3uLm6wsPExcbHyMnK0tPU1dbX2Nna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AOlYBtoLC1urIaTZ6dcQz2EswsZCYZE88YfG1drfK2eCcbeT26dnsbueKaSyunfyzEu+ymA2SeXkEFcc7kznphs42viOyh0i1tDaWWkNbW9xjfDHpkkaNuCD5l2AdHUHPTDZ+42C+t/60EtjE8QQRXWs3cU8STQuNNjkR1DK2bh8gg9eDSXlvb2F9PY6fDHBZR3Fg/kxKFjjlM/zAAcAlQhIGOoPetiGy0P7B/Z8ehhLOZlZrf+ynWNidmCy7MZ+dM56YbONjbZbRNLgtYrW10qSC33q6RLpsiIrEoQcbAAQXU57ENnGxsCdvvv8AkDuzB8O6NI+orqSadp9qsd7dM93E2bi4BeRdjjYMDJB+8fujj0Nb043viW/kHh7S9YMVjCQL19rLzLwmY2649R2rpbe6tkRUgtLqNXO4AWMqDLFDk/LxzICc9Pnz9xsEd1bNL5qWl0skwRS5sZVJHy7QSV7eaOvT5+m18J6qw76tnK6VZ6TqFldzavJHdmytoTb3M/DRQeSrCVOfkJbedwIOVxn5RU32W+lg0iQ3DWk+tQpDqWFwzERFiw/uvhSmfQj+6K2ja6LdG0Mmi7zBt+zGTS3/AHOShG3KfJy656Yw2cbG22vtVtO8LtaXTMCGjL2MoKFgozyvy8SgH0+fP3XxTaf9f1uLUswQRWtvHb28axRRKEREGAqjgACl0lNs2ots277oHOzG791GM52LnpjOX6Y3DG1YE1CKTZtgvBv243WUw67MZyvH+sXOemGzjY2JdEw5vp1ieNZ51kHmQmNmBhj5IZFOeMc7iMYyMbFTdwSNSiiipKCiiigAooooAy9L/wBRpf8A14/0jrUrL0v/AFGl/wDXj/SOtSgAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAy9L/wBRpf8A14/0jrUrL0v/AFGl/wDXj/SOtSgAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooA//Z&quot; /&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;span style=&quot;color: grey;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;span style=&quot;color: grey;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;but to have the intended result i have done it like that&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;IF&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: magenta;&quot;&gt;Object_ID&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: red;&quot;&gt;&#39;tempdb..#temp_sch_code&#39;&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt;
&lt;span style=&quot;color: grey;&quot;&gt;is&lt;/span&gt; &lt;span style=&quot;color: grey;&quot;&gt;Not&lt;/span&gt; &lt;span style=&quot;color: grey;&quot;&gt;Null&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;Begin&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;DROP&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;TABLE&lt;/span&gt; #temp_sch_code&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;end&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;IF&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: magenta;&quot;&gt;Object_ID&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: red;&quot;&gt;&#39;tempdb..#temp_result&#39;&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt;
&lt;span style=&quot;color: grey;&quot;&gt;is&lt;/span&gt; &lt;span style=&quot;color: grey;&quot;&gt;Not&lt;/span&gt; &lt;span style=&quot;color: grey;&quot;&gt;Null&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;Begin&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;DROP&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;TABLE&lt;/span&gt; #temp_result&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;end&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;create&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: blue;&quot;&gt;table&lt;/span&gt; #temp_result &lt;span style=&quot;color: green;&quot;&gt;--
because we will insert item into it in a loop&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: grey; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;(&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; sch_code &lt;span style=&quot;color: blue;&quot;&gt;varchar&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;10&lt;span style=&quot;color: grey;&quot;&gt;),&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; FUND_MANAGERS &lt;span style=&quot;color: blue;&quot;&gt;VARCHAR&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: magenta;&quot;&gt;MAX&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: grey; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;)&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;declare&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; @sch_code &lt;span style=&quot;color: blue;&quot;&gt;as&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;varchar&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;10&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;select&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; sch_code&lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt;0 &lt;span style=&quot;color: blue;&quot;&gt;as&lt;/span&gt; ser_no &lt;span style=&quot;color: blue;&quot;&gt;into&lt;/span&gt; #temp_sch_code &lt;span style=&quot;color: blue;&quot;&gt;from&lt;/span&gt;
SCHEME_INFO&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;while&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: grey;&quot;&gt;exists(&lt;/span&gt;&lt;span style=&quot;color: blue;&quot;&gt;select&lt;/span&gt;
sch_code &lt;span style=&quot;color: blue;&quot;&gt;from&lt;/span&gt; #temp_sch_code &lt;span style=&quot;color: blue;&quot;&gt;where&lt;/span&gt; ser_no&lt;span style=&quot;color: grey;&quot;&gt;=&lt;/span&gt;0&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;begin&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;select&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;top&lt;/span&gt;
1 @sch_code&lt;span style=&quot;color: grey;&quot;&gt;=&lt;/span&gt;sch_code &lt;span style=&quot;color: blue;&quot;&gt;from&lt;/span&gt;
#temp_sch_code &lt;span style=&quot;color: blue;&quot;&gt;where&lt;/span&gt; ser_no&lt;span style=&quot;color: grey;&quot;&gt;=&lt;/span&gt;0&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;INSERT&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;INTO&lt;/span&gt;&amp;nbsp; #temp_result&lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;select&lt;/span&gt; @sch_code&lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt;&lt;span style=&quot;color: magenta;&quot;&gt;STUFF&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;((&lt;/span&gt;&lt;span style=&quot;color: blue;&quot;&gt;SELECT&lt;/span&gt;&amp;nbsp; &lt;span style=&quot;color: red;&quot;&gt;&#39;,&#39;&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;+&lt;/span&gt;FM&lt;span style=&quot;color: grey;&quot;&gt;.&lt;/span&gt;FUND_NAME &lt;span style=&quot;color: blue;&quot;&gt;FROM&lt;/span&gt; SCH_FUND SF &lt;span style=&quot;color: grey;&quot;&gt;INNER&lt;/span&gt;
&lt;span style=&quot;color: grey;&quot;&gt;JOIN&lt;/span&gt; FUND_MANAGER FM &lt;span style=&quot;color: blue;&quot;&gt;ON&lt;/span&gt;
SF&lt;span style=&quot;color: grey;&quot;&gt;.&lt;/span&gt;FUND_CODE&lt;span style=&quot;color: grey;&quot;&gt;=&lt;/span&gt;FM&lt;span style=&quot;color: grey;&quot;&gt;.&lt;/span&gt;FUND_CODE &lt;span style=&quot;color: blue;&quot;&gt;where&lt;/span&gt; SF&lt;span style=&quot;color: grey;&quot;&gt;.&lt;/span&gt;SCH_CODE&lt;span style=&quot;color: grey;&quot;&gt;=&lt;/span&gt;@sch_code &lt;span style=&quot;color: blue;&quot;&gt;FOR&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;XML&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;PATH&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: red;&quot;&gt;&#39;&#39;&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;))&lt;/span&gt; &lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt; 1 &lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt; 1 &lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt; &lt;span style=&quot;color: red;&quot;&gt;&#39;&#39;&lt;/span&gt; &lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt; &lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;update&lt;/span&gt; #temp_sch_code &lt;span style=&quot;color: blue;&quot;&gt;set&lt;/span&gt; ser_no&lt;span style=&quot;color: grey;&quot;&gt;=&lt;/span&gt;1 &lt;span style=&quot;color: blue;&quot;&gt;where&lt;/span&gt; sch_code &lt;span style=&quot;color: grey;&quot;&gt;=&lt;/span&gt;
@sch_code &lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;end&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/div&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3; color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt; line-height: 115%;&quot;&gt;SELECT&lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3; color: grey;&quot;&gt;*&lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;from&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;#temp_result&lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&amp;nbsp; &lt;/div&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt; line-height: 115%;&quot;&gt;&lt;/span&gt;

&lt;br /&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;Which then returns :&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;img alt=&quot;&quot; src=&quot;data:image/jpeg;base64,/9j/4AAQSkZJRgABAQEAYABgAAD/2wBDAAoHBwgHBgoICAgLCgoLDhgQDg0NDh0VFhEYIx8lJCIfIiEmKzcvJik0KSEiMEExNDk7Pj4+JS5ESUM8SDc9Pjv/2wBDAQoLCw4NDhwQEBw7KCIoOzs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozv/wAARCACmAaADASIAAhEBAxEB/8QAHwAAAQUBAQEBAQEAAAAAAAAAAAECAwQFBgcICQoL/8QAtRAAAgEDAwIEAwUFBAQAAAF9AQIDAAQRBRIhMUEGE1FhByJxFDKBkaEII0KxwRVS0fAkM2JyggkKFhcYGRolJicoKSo0NTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqD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UUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFAGI//Iftvqv/AKBNWlY/6hv+u0v/AKG1Zr/8h+2+q/8AoE1aVj/qG/67S/8AobUAWaKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKAMR/wDkP231X/0CatKx/wBQ3/XaX/0NqKKALNFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFAH/2Q==&quot; /&gt;&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&amp;nbsp;Now i will explain a specific term&amp;nbsp;&lt;/span&gt; &lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;b&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;span style=&quot;color: grey;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: blue;&quot;&gt;FOR&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;XML&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;PATH&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: red;&quot;&gt;&#39;&#39;&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/1354197471922627812/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2012/06/concat-multiple-rows-into-single-using.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/1354197471922627812'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/1354197471922627812'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2012/06/concat-multiple-rows-into-single-using.html' title='Merge multiple rows into a single using T-Sql stuff function'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjfWltKMGqklPTem41Dyg_qKfCYu8imgDryBSytFcIhfBnVRuq86iod3K0pTx7k8TVSkxauyNNnGLXeomdqb-3tweAV20Toy5gFIw_0NM5DKhkpBTRyrgQf7Xwv-Q4CpUZQJtKwqGYKzFbz/s72-c/stuff.png" height="72" width="72"/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-1396258892096433204</id><published>2012-06-08T10:06:00.000-07:00</published><updated>2012-06-08T10:11:44.943-07:00</updated><title type='text'>Drag and Drop item between two list boxes when the source listbox is databound</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
Hi , i am going to demonstrate an application where i will drag one 
item from a listbox and drop into another . The specialty here is that 
the source and the target both the list box will be data bound and so it
 will be a little tricky .&lt;br /&gt;
&lt;br /&gt;
so lets&amp;nbsp; first fill our source list box with data from database , but setting its datasource property .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;listBox1.DataSource = dtable; &lt;span style=&quot;color: green;&quot;&gt;// Some datatable contains data&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;listBox1.DisplayMember = &lt;span style=&quot;color: #a31515;&quot;&gt;&quot;NAME&quot;&lt;/span&gt;;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;listBox1.ValueMember = &lt;span style=&quot;color: #a31515;&quot;&gt;&quot;Person_ID&quot;&lt;/span&gt;;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;So this now looks like&amp;nbsp; :&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjqOkb2Q9JoE6H_SXTD458LXv-jIevIQlJRA53bT3wmLwsqiRsDDAbzUSt3cGik6h3Pnu-xS081HklqiPesk3uKZLm2_5otrR29PRO4mWHyoNKsJkDBrkT4JTZVAXIgCXNzB1mKuS2hc0Wm/s1600/1.png&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;290&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjqOkb2Q9JoE6H_SXTD458LXv-jIevIQlJRA53bT3wmLwsqiRsDDAbzUSt3cGik6h3Pnu-xS081HklqiPesk3uKZLm2_5otrR29PRO4mWHyoNKsJkDBrkT4JTZVAXIgCXNzB1mKuS2hc0Wm/s400/1.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
We declare a datatable globally which will change when the item is dropped . 

&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #2b91af; font-family: Consolas; font-size: 9.5pt;&quot;&gt;DataTable&lt;/span&gt;&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt; dtableSelected = &lt;span style=&quot;color: blue;&quot;&gt;new&lt;/span&gt; &lt;span style=&quot;color: #2b91af;&quot;&gt;DataTable&lt;/span&gt;();&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;dtableSelected.Columns.Add(&lt;span style=&quot;color: #a31515;&quot;&gt;&quot;Name&quot;&lt;/span&gt;);&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;dtableSelected.Columns.Add(&lt;span style=&quot;color: #a31515;&quot;&gt;&quot;Id&quot;&lt;/span&gt;);&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&lt;span style=&quot;color: #2b91af;&quot;&gt;DataColumn&lt;/span&gt;[] keys = &lt;span style=&quot;color: blue;&quot;&gt;new&lt;/span&gt;
&lt;span style=&quot;color: #2b91af;&quot;&gt;DataColumn&lt;/span&gt;[1];&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&lt;span style=&quot;color: #2b91af;&quot;&gt;DataColumn&lt;/span&gt; dc = dtableSelected.Columns[&lt;span style=&quot;color: #a31515;&quot;&gt;&quot;Id&quot;&lt;/span&gt;];&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;keys[0] = dc;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;dtableSelected.PrimaryKey = keys; &lt;span style=&quot;color: green;&quot;&gt;// So that
selected items are ubique&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&lt;span style=&quot;color: green;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;Now
 we will call the mousedown event for the source listbox where we will 
actually drag the selected items text and value field using DoDragDrop 
Function&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;private&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;void&lt;/span&gt;
listBox1_MouseDown(&lt;span style=&quot;color: blue;&quot;&gt;object&lt;/span&gt; sender, &lt;span style=&quot;color: #2b91af;&quot;&gt;MouseEventArgs&lt;/span&gt; e)&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;if&lt;/span&gt; (listBox1.SelectedItems.Count == 0)&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
&lt;span style=&quot;color: blue;&quot;&gt;return&lt;/span&gt;;&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style=&quot;color: #2b91af;&quot;&gt;DataRowView&lt;/span&gt;
view = (&lt;span style=&quot;color: #2b91af;&quot;&gt;DataRowView&lt;/span&gt;)listBox1.SelectedItem;&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: #2b91af;&quot;&gt;DragDropEffects&lt;/span&gt; dde1 = DoDragDrop(view,&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
&lt;span style=&quot;color: #2b91af;&quot;&gt;DragDropEffects&lt;/span&gt;.All);&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&lt;span style=&quot;color: green;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&amp;nbsp;&lt;/span&gt; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&lt;span style=&quot;color: green;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;Next we will drop the dragged item&lt;/span&gt; &lt;span style=&quot;color: black;&quot;&gt;into target listbox ( listbox2)&lt;/span&gt; &lt;span style=&quot;color: black;&quot;&gt;So first we need to set the AllowDrop property of listbox2 to True . and call the next event .&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&lt;span style=&quot;color: green;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;

&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: Consolas; font-size: 9.5pt;&quot;&gt;private&lt;/span&gt;&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt; &lt;span style=&quot;color: blue;&quot;&gt;void&lt;/span&gt;
listBox2_DragDrop(&lt;span style=&quot;color: blue;&quot;&gt;object&lt;/span&gt; sender, &lt;span style=&quot;color: #2b91af;&quot;&gt;DragEventArgs&lt;/span&gt; e)&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: #2b91af;&quot;&gt;DataRowView&lt;/span&gt; drv = (&lt;span style=&quot;color: #2b91af;&quot;&gt;DataRowView&lt;/span&gt;)e.Data.GetData(&lt;span style=&quot;color: blue;&quot;&gt;typeof&lt;/span&gt;(&lt;span style=&quot;color: #2b91af;&quot;&gt;DataRowView&lt;/span&gt;));&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;try&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
&lt;span style=&quot;color: #2b91af;&quot;&gt;DataRow&lt;/span&gt; dr = dtableSelected.NewRow();&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
dr[&lt;span style=&quot;color: #a31515;&quot;&gt;&quot;Name&quot;&lt;/span&gt;] = drv[&lt;span style=&quot;color: #a31515;&quot;&gt;&quot;NAME&quot;&lt;/span&gt;].ToString();&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
dr[&lt;span style=&quot;color: #a31515;&quot;&gt;&quot;Id&quot;&lt;/span&gt;] = drv[&lt;span style=&quot;color: #a31515;&quot;&gt;&quot;Person_ID&quot;&lt;/span&gt;].ToString();&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
dtableSelected.Rows.Add(dr);&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
listBox2.DataSource = dtableSelected;&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
listBox2.DisplayMember = &lt;span style=&quot;color: #a31515;&quot;&gt;&quot;Name&quot;&lt;/span&gt;;&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
listBox2.ValueMember = &lt;span style=&quot;color: #a31515;&quot;&gt;&quot;Id&quot;&lt;/span&gt;;&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;catch&lt;/span&gt; (&lt;span style=&quot;color: #2b91af;&quot;&gt;ConstraintException&lt;/span&gt;
ex)&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
&lt;span style=&quot;color: #2b91af;&quot;&gt;MessageBox&lt;/span&gt;.Show(drv[&lt;span style=&quot;color: #a31515;&quot;&gt;&quot;NAME&quot;&lt;/span&gt;].ToString() + &lt;span style=&quot;color: #a31515;&quot;&gt;&quot;is already added to list .&quot;&lt;/span&gt; + &lt;span style=&quot;color: #a31515;&quot;&gt;&#39;\n&#39;&lt;/span&gt; + &lt;span style=&quot;color: #a31515;&quot;&gt;&#39;\n&#39;&lt;/span&gt; +
ex.Message.ToString());&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;And during dragging we will do just a bit effect&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3; color: blue;&quot;&gt;private&lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3; color: blue;&quot;&gt;void&lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;
listBox2_DragOver(&lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3; color: blue;&quot;&gt;object&lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt; sender, &lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3; color: #2b91af;&quot;&gt;DragEventArgs&lt;/span&gt;&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt; e)&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
e.Effect = &lt;span style=&quot;color: #2b91af;&quot;&gt;DragDropEffects&lt;/span&gt;.Move;&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #f3f3f3;&quot;&gt;
&lt;span style=&quot;background-color: #f3f3f3;&quot;&gt;

&lt;/span&gt;
&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background-color: #f3f3f3; line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&amp;nbsp;The code is pretty easy . And dragging effect always gives a cool and rel type effect .&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: Consolas; font-size: 9.5pt;&quot;&gt;&lt;br /&gt;
  &lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi_agGTIOFB_a6hK010OZGDDCuebDweQo85XSSniPM1aF_yikE1CGUpUyuxaaQL5-jlMZV6gOWtcroNkoFQhfKSzKPem0B3ttT7FUSuhlChZwZnIqg3uFNXRg1aJZC-ElZw3bJk63Uz8O2q/s1600/2.jpg&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;285&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi_agGTIOFB_a6hK010OZGDDCuebDweQo85XSSniPM1aF_yikE1CGUpUyuxaaQL5-jlMZV6gOWtcroNkoFQhfKSzKPem0B3ttT7FUSuhlChZwZnIqg3uFNXRg1aJZC-ElZw3bJk63Uz8O2q/s400/2.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi_agGTIOFB_a6hK010OZGDDCuebDweQo85XSSniPM1aF_yikE1CGUpUyuxaaQL5-jlMZV6gOWtcroNkoFQhfKSzKPem0B3ttT7FUSuhlChZwZnIqg3uFNXRg1aJZC-ElZw3bJk63Uz8O2q/s1600/2.jpg&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;/a&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/1396258892096433204/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2012/06/drag-and-drop-item-between-two-list.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/1396258892096433204'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/1396258892096433204'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2012/06/drag-and-drop-item-between-two-list.html' title='Drag and Drop item between two list boxes when the source listbox is databound'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjqOkb2Q9JoE6H_SXTD458LXv-jIevIQlJRA53bT3wmLwsqiRsDDAbzUSt3cGik6h3Pnu-xS081HklqiPesk3uKZLm2_5otrR29PRO4mWHyoNKsJkDBrkT4JTZVAXIgCXNzB1mKuS2hc0Wm/s72-c/1.png" height="72" width="72"/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-8736001055192930238</id><published>2012-05-28T08:08:00.000-07:00</published><updated>2012-05-28T08:08:04.674-07:00</updated><title type='text'>Split a string into table rows</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&amp;nbsp;Hi guys , this is a small demonstration where i am going to show how you can split a string joined by some delimiter&amp;nbsp; ( here comma ) , and create table rows from them . This is because sometimes we have to send big string joined by a separator to our Stored procedure and we have to loop through each item of it .. so here is this .. Suppose we have a big string like &lt;span style=&quot;color: red;&quot;&gt;&#39;Sun Day,Mon Day,Tues Day,Wednesday Day&#39;&lt;/span&gt;&lt;br /&gt;
its better to take &lt;span style=&quot;color: blue;&quot;&gt;varchar&lt;/span&gt;(&lt;span style=&quot;color: magenta;&quot;&gt;MAX&lt;/span&gt;)&lt;span style=&quot;background-color: magenta; color: magenta;&quot;&gt;&lt;/span&gt; .. here is our code :&lt;br /&gt;
&lt;br /&gt;
&lt;!--[if gte mso 9]&gt;&lt;xml&gt;
 &lt;w:WordDocument&gt;
  &lt;w:View&gt;Normal&lt;/w:View&gt;
  &lt;w:Zoom&gt;0&lt;/w:Zoom&gt;
  &lt;w:TrackMoves/&gt;
  &lt;w:TrackFormatting/&gt;
  &lt;w:PunctuationKerning/&gt;
  &lt;w:ValidateAgainstSchemas/&gt;
  &lt;w:SaveIfXMLInvalid&gt;false&lt;/w:SaveIfXMLInvalid&gt;
  &lt;w:IgnoreMixedContent&gt;false&lt;/w:IgnoreMixedContent&gt;
  &lt;w:AlwaysShowPlaceholderText&gt;false&lt;/w:AlwaysShowPlaceholderText&gt;
  &lt;w:DoNotPromoteQF/&gt;
  &lt;w:LidThemeOther&gt;EN-IN&lt;/w:LidThemeOther&gt;
  &lt;w:LidThemeAsian&gt;X-NONE&lt;/w:LidThemeAsian&gt;
  &lt;w:LidThemeComplexScript&gt;X-NONE&lt;/w:LidThemeComplexScript&gt;
  &lt;w:Compatibility&gt;
   &lt;w:BreakWrappedTables/&gt;
   &lt;w:SnapToGridInCell/&gt;
   &lt;w:WrapTextWithPunct/&gt;
   &lt;w:UseAsianBreakRules/&gt;
   &lt;w:DontGrowAutofit/&gt;
   &lt;w:SplitPgBreakAndParaMark/&gt;
   &lt;w:DontVertAlignCellWithSp/&gt;
   &lt;w:DontBreakConstrainedForcedTables/&gt;
   &lt;w:DontVertAlignInTxbx/&gt;
   &lt;w:Word11KerningPairs/&gt;
   &lt;w:CachedColBalance/&gt;
  &lt;/w:Compatibility&gt;
  &lt;w:BrowserLevel&gt;MicrosoftInternetExplorer4&lt;/w:BrowserLevel&gt;
  &lt;m:mathPr&gt;
   &lt;m:mathFont m:val=&quot;Cambria Math&quot;/&gt;
   &lt;m:brkBin m:val=&quot;before&quot;/&gt;
   &lt;m:brkBinSub m:val=&quot;&amp;#45;-&quot;/&gt;
   &lt;m:smallFrac m:val=&quot;off&quot;/&gt;
   &lt;m:dispDef/&gt;
   &lt;m:lMargin m:val=&quot;0&quot;/&gt;
   &lt;m:rMargin m:val=&quot;0&quot;/&gt;
   &lt;m:defJc m:val=&quot;centerGroup&quot;/&gt;
   &lt;m:wrapIndent m:val=&quot;1440&quot;/&gt;
   &lt;m:intLim m:val=&quot;subSup&quot;/&gt;
   &lt;m:naryLim m:val=&quot;undOvr&quot;/&gt;
  &lt;/m:mathPr&gt;&lt;/w:WordDocument&gt;
&lt;/xml&gt;&lt;![endif]--&gt;&lt;!--[if gte mso 9]&gt;&lt;xml&gt;
 &lt;w:LatentStyles DefLockedState=&quot;false&quot; DefUnhideWhenUsed=&quot;true&quot;
  DefSemiHidden=&quot;true&quot; DefQFormat=&quot;false&quot; DefPriority=&quot;99&quot;
  LatentStyleCount=&quot;267&quot;&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;0&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;Normal&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;9&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;heading 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;9&quot; QFormat=&quot;true&quot; Name=&quot;heading 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;9&quot; QFormat=&quot;true&quot; Name=&quot;heading 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;9&quot; QFormat=&quot;true&quot; Name=&quot;heading 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;9&quot; QFormat=&quot;true&quot; Name=&quot;heading 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;9&quot; QFormat=&quot;true&quot; Name=&quot;heading 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;9&quot; QFormat=&quot;true&quot; Name=&quot;heading 7&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;9&quot; QFormat=&quot;true&quot; Name=&quot;heading 8&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;9&quot; QFormat=&quot;true&quot; Name=&quot;heading 9&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;39&quot; Name=&quot;toc 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;39&quot; Name=&quot;toc 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;39&quot; Name=&quot;toc 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;39&quot; Name=&quot;toc 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;39&quot; Name=&quot;toc 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;39&quot; Name=&quot;toc 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;39&quot; Name=&quot;toc 7&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;39&quot; Name=&quot;toc 8&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;39&quot; Name=&quot;toc 9&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;35&quot; QFormat=&quot;true&quot; Name=&quot;caption&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;10&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;Title&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;1&quot; Name=&quot;Default Paragraph Font&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;11&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;Subtitle&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;22&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;Strong&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;20&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;Emphasis&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;59&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Table Grid&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; UnhideWhenUsed=&quot;false&quot; Name=&quot;Placeholder Text&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;1&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;No Spacing&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;60&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Shading&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;61&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light List&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;62&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Grid&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;63&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;64&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;65&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;66&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;67&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;68&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;69&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;70&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Dark List&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;71&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Shading&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;72&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful List&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;73&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Grid&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;60&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Shading Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;61&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light List Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;62&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Grid Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;63&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 1 Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;64&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 2 Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;65&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 1 Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; UnhideWhenUsed=&quot;false&quot; Name=&quot;Revision&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;34&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;List Paragraph&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;29&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;Quote&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;30&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;Intense Quote&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;66&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 2 Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;67&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 1 Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;68&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 2 Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;69&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 3 Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;70&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Dark List Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;71&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Shading Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;72&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful List Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;73&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Grid Accent 1&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;60&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Shading Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;61&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light List Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;62&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Grid Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;63&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 1 Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;64&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 2 Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;65&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 1 Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;66&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 2 Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;67&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 1 Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;68&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 2 Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;69&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 3 Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;70&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Dark List Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;71&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Shading Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;72&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful List Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;73&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Grid Accent 2&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;60&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Shading Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;61&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light List Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;62&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Grid Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;63&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 1 Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;64&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 2 Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;65&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 1 Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;66&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 2 Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;67&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 1 Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;68&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 2 Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;69&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 3 Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;70&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Dark List Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;71&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Shading Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;72&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful List Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;73&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Grid Accent 3&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;60&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Shading Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;61&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light List Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;62&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Grid Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;63&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 1 Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;64&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 2 Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;65&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 1 Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;66&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 2 Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;67&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 1 Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;68&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 2 Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;69&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 3 Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;70&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Dark List Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;71&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Shading Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;72&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful List Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;73&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Grid Accent 4&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;60&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Shading Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;61&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light List Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;62&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Grid Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;63&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 1 Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;64&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 2 Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;65&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 1 Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;66&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 2 Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;67&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 1 Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;68&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 2 Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;69&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 3 Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;70&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Dark List Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;71&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Shading Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;72&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful List Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;73&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Grid Accent 5&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;60&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Shading Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;61&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light List Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;62&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Light Grid Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;63&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 1 Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;64&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Shading 2 Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;65&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 1 Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;66&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium List 2 Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;67&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 1 Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;68&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 2 Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;69&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Medium Grid 3 Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;70&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Dark List Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;71&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Shading Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;72&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful List Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;73&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; Name=&quot;Colorful Grid Accent 6&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;19&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;Subtle Emphasis&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;21&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;Intense Emphasis&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;31&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;Subtle Reference&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;32&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;Intense Reference&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;33&quot; SemiHidden=&quot;false&quot;
   UnhideWhenUsed=&quot;false&quot; QFormat=&quot;true&quot; Name=&quot;Book Title&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;37&quot; Name=&quot;Bibliography&quot;/&gt;
  &lt;w:LsdException Locked=&quot;false&quot; Priority=&quot;39&quot; QFormat=&quot;true&quot; Name=&quot;TOC Heading&quot;/&gt;
 &lt;/w:LatentStyles&gt;
&lt;/xml&gt;&lt;![endif]--&gt;&lt;!--[if gte mso 10]&gt;
&lt;style&gt;
 /* Style Definitions */
 table.MsoNormalTable
 {mso-style-name:&quot;Table Normal&quot;;
 mso-tstyle-rowband-size:0;
 mso-tstyle-colband-size:0;
 mso-style-noshow:yes;
 mso-style-priority:99;
 mso-style-qformat:yes;
 mso-style-parent:&quot;&quot;;
 mso-padding-alt:0cm 5.4pt 0cm 5.4pt;
 mso-para-margin-top:0cm;
 mso-para-margin-right:0cm;
 mso-para-margin-bottom:10.0pt;
 mso-para-margin-left:0cm;
 line-height:115%;
 mso-pagination:widow-orphan;
 font-size:11.0pt;
 font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;
 mso-ascii-font-family:Calibri;
 mso-ascii-theme-font:minor-latin;
 mso-fareast-font-family:&quot;Times New Roman&quot;;
 mso-fareast-theme-font:minor-fareast;
 mso-hansi-font-family:Calibri;
 mso-hansi-theme-font:minor-latin;
 mso-bidi-font-family:&quot;Times New Roman&quot;;
 mso-bidi-theme-font:minor-bidi;}
&lt;/style&gt;
&lt;![endif]--&gt;

&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;IF&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt; &lt;span style=&quot;color: magenta;&quot;&gt;Object_ID&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: red;&quot;&gt;&#39;tempdb..#TempSch_Codes&#39;&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt;
&lt;span style=&quot;color: grey;&quot;&gt;is&lt;/span&gt; &lt;span style=&quot;color: grey;&quot;&gt;Not&lt;/span&gt; &lt;span style=&quot;color: grey;&quot;&gt;Null&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;Begin&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;&lt;span style=&quot;mso-spacerun: yes;&quot;&gt;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: blue;&quot;&gt;DROP&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;TABLE&lt;/span&gt; #TempSch_Codes&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;end&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt; &lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;CREATE&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt; &lt;span style=&quot;color: blue;&quot;&gt;TABLE&lt;/span&gt; #TempSch_Codes&lt;span style=&quot;color: blue;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;ITEM &lt;span style=&quot;color: blue;&quot;&gt;VARCHAR&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: magenta;&quot;&gt;Max&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;),&lt;/span&gt;ISDONE&lt;span style=&quot;mso-spacerun: yes;&quot;&gt;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: blue;&quot;&gt;INT&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt;RowID &lt;span style=&quot;color: blue;&quot;&gt;int&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;identity&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;1&lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt;1&lt;span style=&quot;color: grey;&quot;&gt;))&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;declare&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt; @name &lt;span style=&quot;color: blue;&quot;&gt;as&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;varchar&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: magenta;&quot;&gt;MAX&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;),&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;&lt;span style=&quot;mso-spacerun: yes;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;@intPos &lt;span style=&quot;color: blue;&quot;&gt;as&lt;/span&gt;
&lt;span style=&quot;color: blue;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;&lt;span style=&quot;mso-spacerun: yes;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;@portion &lt;span style=&quot;color: blue;&quot;&gt;as&lt;/span&gt;
&lt;span style=&quot;color: blue;&quot;&gt;varchar&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: magenta;&quot;&gt;Max&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;set&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt; @name&lt;span style=&quot;color: grey;&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color: red;&quot;&gt;&#39;Sun Day,Mon Day,Tues
Day,Wednesday Day&#39;&lt;/span&gt; &lt;span style=&quot;color: green;&quot;&gt;-- Main string --&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;while&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt; &lt;span style=&quot;color: magenta;&quot;&gt;CHARINDEX&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: red;&quot;&gt;&#39;,&#39;&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt;@name&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt; &lt;span style=&quot;color: grey;&quot;&gt;&amp;gt;&lt;/span&gt; 0&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;begin&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;&lt;span style=&quot;mso-spacerun: yes;&quot;&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: blue;&quot;&gt;set&lt;/span&gt; @intPos&lt;span style=&quot;color: grey;&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color: magenta;&quot;&gt;CHARINDEX&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: red;&quot;&gt;&#39;,&#39;&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt;@name&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;&lt;span style=&quot;mso-spacerun: yes;&quot;&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: blue;&quot;&gt;set&lt;/span&gt; @portion&lt;span style=&quot;color: grey;&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color: magenta;&quot;&gt;SUBSTRING&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;@name&lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt;1&lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt;@intPos&lt;span style=&quot;color: grey;&quot;&gt;-&lt;/span&gt;1&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt; &lt;span style=&quot;color: green;&quot;&gt;-- get the particular
portion ---&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;&lt;span style=&quot;mso-spacerun: yes;&quot;&gt;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;&lt;span style=&quot;mso-spacerun: yes;&quot;&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: blue;&quot;&gt;PRINT&lt;/span&gt;
@portion&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;&lt;span style=&quot;mso-spacerun: yes;&quot;&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: blue;&quot;&gt;INSERT&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;INTO&lt;/span&gt; #TempSch_Codes &lt;span style=&quot;color: blue;&quot;&gt;VALUES&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: magenta;&quot;&gt;LTRIM&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;@portion&lt;span style=&quot;color: grey;&quot;&gt;),&lt;/span&gt;0&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;&lt;span style=&quot;mso-spacerun: yes;&quot;&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: blue;&quot;&gt;SET&lt;/span&gt; @name&lt;span style=&quot;color: grey;&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color: magenta;&quot;&gt;REPLACE&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;@name&lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt;@portion&lt;span style=&quot;color: grey;&quot;&gt;+&lt;/span&gt;&lt;span style=&quot;color: red;&quot;&gt;&#39;,&#39;&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;,&lt;/span&gt;&lt;span style=&quot;color: red;&quot;&gt;&#39;&#39;&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt; &lt;span style=&quot;color: green;&quot;&gt;-- refresh the main
string again ---&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;&lt;span style=&quot;mso-spacerun: yes;&quot;&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;end&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;PRINT&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt; @name&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;INSERT&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt; &lt;span style=&quot;color: blue;&quot;&gt;INTO&lt;/span&gt; #TempSch_Codes &lt;span style=&quot;color: blue;&quot;&gt;VALUES&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: magenta;&quot;&gt;LTRIM&lt;/span&gt;&lt;span style=&quot;color: grey;&quot;&gt;(&lt;/span&gt;@name&lt;span style=&quot;color: grey;&quot;&gt;),&lt;/span&gt;0&lt;span style=&quot;color: grey;&quot;&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;span style=&quot;color: blue; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt;SELECT&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10.0pt; mso-no-proof: yes;&quot;&gt; &lt;span style=&quot;color: grey;&quot;&gt;*&lt;/span&gt; &lt;span style=&quot;color: blue;&quot;&gt;FROM&lt;/span&gt; #TempSch_Codes&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;Looping through the temporary table would give the result ..&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhE3zaSNXVGoI5WrNcbqbAYfA9N0muniugCdp-cWXW-lZvqkgT-R2Gv0dhWmxmelSMJqIjqxHVDw6jk8npJ0JVS1h9RDxeMmU0Y_TeMhP-_ydiGj_fYpy_JOu8lYy7mOJ0qAXHNXD9woAh1/s1600/blog_1.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;88&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhE3zaSNXVGoI5WrNcbqbAYfA9N0muniugCdp-cWXW-lZvqkgT-R2Gv0dhWmxmelSMJqIjqxHVDw6jk8npJ0JVS1h9RDxeMmU0Y_TeMhP-_ydiGj_fYpy_JOu8lYy7mOJ0qAXHNXD9woAh1/s400/blog_1.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: normal; margin-bottom: .0001pt; margin-bottom: 0cm; mso-layout-grid-align: none; text-autospace: none;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/8736001055192930238/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2012/05/split-string-into-table-rows.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/8736001055192930238'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/8736001055192930238'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2012/05/split-string-into-table-rows.html' title='Split a string into table rows'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhE3zaSNXVGoI5WrNcbqbAYfA9N0muniugCdp-cWXW-lZvqkgT-R2Gv0dhWmxmelSMJqIjqxHVDw6jk8npJ0JVS1h9RDxeMmU0Y_TeMhP-_ydiGj_fYpy_JOu8lYy7mOJ0qAXHNXD9woAh1/s72-c/blog_1.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-3370522622930808554</id><published>2012-01-20T21:05:00.000-08:00</published><updated>2012-01-20T21:12:54.771-08:00</updated><title type='text'>Changing Datatype of a datatable column at runtime</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;Suppose i have a datatable with data filled in .. but when i want to show the data in a grid view i want the date column (&quot;dd / MMM / yyyy&quot;) to be formatted like yyyyMMdd ..this is more like a string .. so i will have to change the format of the data at the run time and bind it to the grid view . The datatable is&lt;br /&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhbb9r32qeenOXCCXpcWUKzAtI7Ujtbjd_nCmouVNkr1e7Mm0mreRPhbzS1fHhJBZz9628V4A8QEjmILcqcddYaCWzRettCOkElrQURMgWh_Ejao77HmlLW5DaVJ0ArN-ddxMFyTVGMP8-Z/s1600/1.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;65&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhbb9r32qeenOXCCXpcWUKzAtI7Ujtbjd_nCmouVNkr1e7Mm0mreRPhbzS1fHhJBZz9628V4A8QEjmILcqcddYaCWzRettCOkElrQURMgWh_Ejao77HmlLW5DaVJ0ArN-ddxMFyTVGMP8-Z/s400/1.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;The common error when you want to change the data format , suppose for that case datetime to string is :&lt;br /&gt;
&lt;b style=&quot;color: purple;&quot;&gt;String was not recognized as a valid DateTime.Couldn&#39;t store &amp;lt;20110901&amp;gt; in date Column.&amp;nbsp; Expected type is DateTime.&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
because when the data is filled in the column datatype is automatically set to datetime ...&lt;br /&gt;
now suppose we first change the type of the column datetime to string and then change the value ...&lt;br /&gt;
the error shows is :&lt;br /&gt;
&lt;b style=&quot;color: purple;&quot;&gt;Cannot change DataType of a column once it has data.&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
so we need the solution and we need empty datatable with respective columns datatype been changed and then insert the formatted value ... so our solution will be start by cloning a new data table from the current datatable .. hold all the data in an object array .. loop through it .. check the datacolumn if datetime ... if datetime then change the datatype of the cloned datatable to string .. then add the rows .. finally bind the cloned new data table to the gridview&amp;nbsp; .. the code is following :&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;DataSet ds = clsData.GetAllData();&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DataTable dt = ds.Tables[&quot;table&quot;];&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DataTable formatDtble = dt.Clone();&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; int countformat = 0;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; foreach (DataRow dr in dt.Rows)&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; object[] objData = dr.ItemArray;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for (int i = 0; i &amp;lt; objData.Length; i++)&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DateTime date;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var val = objData[i].ToString();&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (DateTime.TryParse(val, out date))&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; date = Convert.ToDateTime(val);&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string formatDt = date.ToString(&quot;yyyyMMdd&quot;);&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; val = formatDt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (countformat == 0)&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; formatDtble.Columns[i].DataType = typeof(string);&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; objData[i] = val.ToString();&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; formatDtble.Rows.Add(objData);&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; countformat = countformat + 1;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dataGridView1.DataSource =formatDtble;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
Now the datatable looks like :&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgMcdvFabHcdfIwCBkfAGqI3NJgi5HwRFyL1eZbRDoI5WiS1SfmBeT7MxWEyJQSTbdOZ6WLQ627tmdx6_SAYuHe2SVSzpt46rNj93mNlJbzoExlB3wRxPnis8hAc61s3lkcG_YIujeb89J-/s1600/1.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;63&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgMcdvFabHcdfIwCBkfAGqI3NJgi5HwRFyL1eZbRDoI5WiS1SfmBeT7MxWEyJQSTbdOZ6WLQ627tmdx6_SAYuHe2SVSzpt46rNj93mNlJbzoExlB3wRxPnis8hAc61s3lkcG_YIujeb89J-/s400/1.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;Thanks now .. this is for the case where you don&#39;t&amp;nbsp; run a select statement with all the columns ie. more like a dynamic columns .. because if you fetch columns from database not dynamically then you can format it query .. not programmatically . bye bye ..&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/3370522622930808554/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2012/01/changing-datatype-of-datatable-column.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/3370522622930808554'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/3370522622930808554'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2012/01/changing-datatype-of-datatable-column.html' title='Changing Datatype of a datatable column at runtime'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhbb9r32qeenOXCCXpcWUKzAtI7Ujtbjd_nCmouVNkr1e7Mm0mreRPhbzS1fHhJBZz9628V4A8QEjmILcqcddYaCWzRettCOkElrQURMgWh_Ejao77HmlLW5DaVJ0ArN-ddxMFyTVGMP8-Z/s72-c/1.png" height="72" width="72"/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-4578927291215436310</id><published>2011-11-08T07:50:00.000-08:00</published><updated>2011-11-08T07:50:31.757-08:00</updated><title type='text'>Items collection cannot be modified when the DataSource property is set - Problem is solved</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;Its a common problem that several time we need to add a &lt;b&gt;&quot;-select item -&quot; &lt;/b&gt;or some thing like that , at the top of the selection list like&lt;b&gt; combo box&lt;/b&gt; , its no problem if we add item one by one in a loop but , it throws an exception while we set a &lt;b&gt;datasource &lt;/b&gt;to the combo box , the error is &lt;b&gt;&quot;Items collection cannot be modified when the DataSource property is set.&quot;&lt;/b&gt; ,,&amp;nbsp; but its solved if we&amp;nbsp; deal it with &lt;b&gt;datarow&lt;/b&gt; property , our common code is lie that ,,&lt;br /&gt;
&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;combocategory.DataSource = ds.Tables[&quot;MST_CATEGORY&quot;];&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; combocategory.DisplayMember = &quot;CATEGORY_NAME&quot;;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; combocategory.ValueMember = &quot;CATEGORY_ID&quot;;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; combocategory.Items.Insert(0, &quot;-select-&quot;);&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
Now , we will change it to the following :&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;color: blue;&quot;&gt;DataRow dr = ds.Tables[&quot;MST_CATEGORY&quot;].NewRow(); &lt;span style=&quot;color: #38761d;&quot;&gt;// add a new row&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dr[0] = &quot;-- select --&quot;;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style=&quot;color: #38761d;&quot;&gt; // add value to the row&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ds.Tables[&quot;MST_CATEGORY&quot;].Rows.InsertAt(dr, 0); &lt;span style=&quot;color: #38761d;&quot;&gt;// insert the row into the dataset&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: #38761d;&quot;&gt;// at 0 position &lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; combocategory.DataSource = ds.Tables[&quot;MST_CATEGORY&quot;];&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; combocategory.DisplayMember = &quot;CATEGORY_NAME&quot;;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; combocategory.ValueMember = &quot;CATEGORY_ID&quot;;&lt;/div&gt;&lt;br /&gt;
So problem is solved , Than you :)&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/4578927291215436310/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/11/items-collection-cannot-be-modified.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/4578927291215436310'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/4578927291215436310'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/11/items-collection-cannot-be-modified.html' title='Items collection cannot be modified when the DataSource property is set - Problem is solved'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-236427605751960158</id><published>2011-10-15T10:30:00.000-07:00</published><updated>2011-10-15T10:30:36.253-07:00</updated><title type='text'>Importance of GO statement in T-SQL</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;We use &lt;b&gt;&#39;GO&#39;&lt;/b&gt; statement in &lt;b&gt;sql server&lt;/b&gt;&amp;nbsp; , programming ,&amp;nbsp; often we don&#39;t care about it , but its very important for long&lt;b&gt; T_SQL&lt;/b&gt; programming&amp;nbsp; , its actually&lt;b&gt; batch terminator&lt;/b&gt; , as in my last article &lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;&lt;a href=&quot;http://mynecessarycode.blogspot.com/2011/10/get-nth-data-from-dattableabase-in-t.html#%21/2011/10/get-nth-data-from-dattableabase-in-t.html&quot;&gt;http://mynecessarycode.blogspot.com/2011/10/get-nth-data-from-dattableabase-in-t.html#!/2011/10/get-nth-data-from-dattableabase-in-t.html&lt;/a&gt;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
if i don&#39;t use the&lt;b&gt; &#39;GO&#39;&lt;/b&gt; keyword&amp;nbsp; it will show error , i used &lt;b&gt;GO&lt;/b&gt; so that i tell my program to do the rest of the wor after deleting the existing table &lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/236427605751960158/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/importance-of-go-statement-in-t-sql.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/236427605751960158'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/236427605751960158'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/importance-of-go-statement-in-t-sql.html' title='Importance of GO statement in T-SQL'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-5942139208421447787</id><published>2011-10-12T07:29:00.000-07:00</published><updated>2011-10-12T07:29:55.113-07:00</updated><title type='text'>Easy way to export  Excel data into a Datatable</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;I have an &lt;b&gt;excel &lt;/b&gt;file and i want to &lt;b&gt;export &lt;/b&gt;all the &lt;b&gt;data &lt;/b&gt;of the &lt;b&gt;excel&amp;nbsp; &lt;/b&gt;along with the headers into a &lt;b&gt;DataTable&amp;nbsp; &lt;/b&gt;for this i have the following &lt;b&gt;excel &lt;/b&gt;file ,&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEidMcBvtGpi_Hw_UZOKZBXL60vwbXBiWBylIcRja-hFuoIsd9r5RPoJTWV6KmrNGaHIwSL9BgIrHcwTWWFQ23ZKXKCe1Hixu7jcV-MUy-DMATICTgMeLmhTepXTX1zVth9M251Lmf9Ghc9i/s1600/EXCEL_1.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;225&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEidMcBvtGpi_Hw_UZOKZBXL60vwbXBiWBylIcRja-hFuoIsd9r5RPoJTWV6KmrNGaHIwSL9BgIrHcwTWWFQ23ZKXKCe1Hixu7jcV-MUy-DMATICTgMeLmhTepXTX1zVth9M251Lmf9Ghc9i/s400/EXCEL_1.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
i assume i don&#39;t know&amp;nbsp; the last column name and all , so i will pass everything as a variable , to get the column name from the column index you must visit the following site&lt;br /&gt;
&lt;b&gt;&lt;a href=&quot;http://stackoverflow.com/questions/297213/translate-an-index-into-an-excel-column-name&quot;&gt;http://stackoverflow.com/questions/297213/translate-an-index-into-an-excel-column-name&lt;/a&gt;&amp;nbsp;&lt;/b&gt;&lt;br /&gt;
, the function there &quot;ColumnName&quot; i have used&lt;br /&gt;
&lt;br /&gt;
i am still giving you the function&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;string ColumnName(int index)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; index -= 1; //adjust so it matches 0-indexed array rather than 1-indexed column&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; int quotient = index / 26;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (quotient &amp;gt; 0)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return ColumnName(quotient) + chars[index % 26].ToString();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; else&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return chars[index % 26].ToString();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; private char[] chars = new char[] { &#39;A&#39;, &#39;B&#39;, &#39;C&#39;, &#39;D&#39;, &#39;E&#39;, &#39;F&#39;, &#39;G&#39;, &#39;H&#39;, &#39;I&#39;, &#39;J&#39;, &#39;K&#39;, &#39;L&#39;, &#39;M&#39;, &#39;N&#39;, &#39;O&#39;, &#39;P&#39;, &#39;Q&#39;, &#39;R&#39;, &#39;S&#39;, &#39;T&#39;, &#39;U&#39;, &#39;V&#39;, &#39;W&#39;, &#39;X&#39;, &#39;Y&#39;, &#39;Z&#39; };&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
now the following code will &lt;b&gt;export &lt;/b&gt;the &lt;b&gt;excel &lt;/b&gt;into the &lt;b&gt;datatable &lt;/b&gt;, read the comments as i have described the steps there : and the initializations are given in my previous posts , you can follow :&lt;br /&gt;
&lt;b&gt;&lt;a href=&quot;http://mynecessarycode.blogspot.com/2011/10/tips-and-tricks-on-manipulating-excel.html&quot;&gt;http://mynecessarycode.blogspot.com/2011/10/tips-and-tricks-on-manipulating-excel.html&lt;/a&gt;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
the code is&lt;br /&gt;
&lt;div style=&quot;color: #274e13;&quot;&gt;&lt;b&gt;&lt;br /&gt;
&lt;/b&gt;&lt;/div&gt;&lt;b&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;exApp = new Excel.ApplicationClass(); // create application&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; exApp.Visible = false;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // making application invisible&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; exWb1 = exApp.Workbooks.Open(@&quot;D:\Book1.xlsx&quot;, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing);&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Excel.Worksheet _sheet = (Excel.Worksheet)exWb1.Worksheets[1];&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var maxColCount = _sheet.UsedRange.Columns.Count;&amp;nbsp; &lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var maxColName = ColumnName(maxColCount);&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var maxRowCount = _sheet.UsedRange.Rows.Count;&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; object[,] _val = (object[,])(_sheet.get_Range(&quot;A&quot;+3,maxColName+maxRowCount)).Value2;&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; #region here we create the datatable from the _val array&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DataTable dTable = new DataTable();&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // i starts from 1 as excel index always starts from 1&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for (int i = 1; i &amp;lt;= maxRowCount-2; i++)&amp;nbsp; // since we dont count the first two rows&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DataRow dRow = dTable.NewRow(); // add a new row&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for (int j = 1; j &amp;lt;= maxColCount; j++)&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (i &amp;lt; 2)&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // adding all the columns along with the same header as the excel &lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // it is added only in the first loop&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dTable.Columns.Add(_sheet.get_Range(ColumnName(j)+1,ColumnName(j)+1).Value2.ToString());&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // j-1 , since datatable index starts from 0&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dRow[j - 1] = _val[i, j].ToString();&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dTable.Rows.Add(dRow); // adding the row to the datatable&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; #endregion&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; exWb1.Close(1, null, null);&lt;/span&gt;&lt;br style=&quot;color: #274e13;&quot; /&gt;&lt;span style=&quot;color: #274e13;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; exApp.Quit();&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
so as long as you have the &lt;b&gt;datatable &lt;/b&gt;you can manipulate it easily and show this anywhere .. thank you &lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/5942139208421447787/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/easy-way-to-export-excel-data-into.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/5942139208421447787'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/5942139208421447787'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/easy-way-to-export-excel-data-into.html' title='Easy way to export  Excel data into a Datatable'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEidMcBvtGpi_Hw_UZOKZBXL60vwbXBiWBylIcRja-hFuoIsd9r5RPoJTWV6KmrNGaHIwSL9BgIrHcwTWWFQ23ZKXKCe1Hixu7jcV-MUy-DMATICTgMeLmhTepXTX1zVth9M251Lmf9Ghc9i/s72-c/EXCEL_1.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-6289237307987512816</id><published>2011-10-11T08:03:00.000-07:00</published><updated>2011-10-11T08:03:15.825-07:00</updated><title type='text'>Concepts of Range  in Excel Application</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;Range or Get_range() method is used widely in fetching data from excel sheet , but what is the exact meaning of range , suppose our previous work book Book1 which we had used , there except the heading the value started from A3 cell &quot;Amit&quot; and ends at the last cell D4 &quot;9979&quot; , so we need to fetch all the data s within this &#39;&lt;br /&gt;
range , it is actually the two extreme ends of the excel , and this represents the rectangular area like this&amp;nbsp; &lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgRirZbv3jdXu8xDl-rKyJc67YMFFIrPnonkJo6X-t72RN-aFjUoVpb40Z2o0sAIyJI9H_4i6a3aN-LEHGlXDWBBTFiZjtrPGrOp6Yg5waa0bG8mHRkAz8wwAhOYsrxEMIZT5aZOKcVj7Vn/s1600/EXCEL_2.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;225&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgRirZbv3jdXu8xDl-rKyJc67YMFFIrPnonkJo6X-t72RN-aFjUoVpb40Z2o0sAIyJI9H_4i6a3aN-LEHGlXDWBBTFiZjtrPGrOp6Yg5waa0bG8mHRkAz8wwAhOYsrxEMIZT5aZOKcVj7Vn/s400/EXCEL_2.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt; &lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;So to get the full range of the data is retrieved by the following code :&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;b&gt;var _value = ((Excel.Worksheet)exWb1.Worksheets[1]).get_Range(&quot;A3&quot;, &quot;D&quot; + ((Excel.Worksheet)exWb1.Worksheets[1]).UsedRange.Rows.Count).Value2;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;b&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; object[,] _val = (object[,])((Excel.Worksheet)exWb1.Worksheets[1]).get_Range(&quot;A3&quot;, &quot;D&quot; + ((Excel.Worksheet)exWb1.Worksheets[1]).UsedRange.Rows.Count).Value2;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;the used range is used to get the last used row of the excel .. as i have pass &quot;D&quot; the max column name , it can also be a variable&amp;nbsp; &lt;br /&gt;
&lt;table border=&quot;0&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; style=&quot;width: 68px;&quot;&gt;&lt;tbody&gt;
&lt;tr height=&quot;20&quot;&gt;&lt;td align=&quot;right&quot; height=&quot;20&quot; style=&quot;height: 15pt; width: 51pt;&quot; width=&quot;68&quot;&gt;&lt;br /&gt;
&lt;/td&gt; &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/6289237307987512816/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/concepts-of-range-in-excel-application.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/6289237307987512816'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/6289237307987512816'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/concepts-of-range-in-excel-application.html' title='Concepts of Range  in Excel Application'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgRirZbv3jdXu8xDl-rKyJc67YMFFIrPnonkJo6X-t72RN-aFjUoVpb40Z2o0sAIyJI9H_4i6a3aN-LEHGlXDWBBTFiZjtrPGrOp6Yg5waa0bG8mHRkAz8wwAhOYsrxEMIZT5aZOKcVj7Vn/s72-c/EXCEL_2.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-4035798040337059928</id><published>2011-10-11T07:20:00.000-07:00</published><updated>2011-10-11T07:21:55.963-07:00</updated><title type='text'>Tips and tricks on manipulating excel from codebehind in c# PART : 2</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;div style=&quot;color: red;&quot;&gt;&lt;b&gt;Today i am going to demonstrate the following actions :&amp;nbsp;&lt;/b&gt;&lt;/div&gt;1) I have an excel with formatted headings , values and sheet name , i want to copy the entire work sheet to another excel workbook , like following&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi8ZsqmbpNsRYrQ4l73yP0ob01A4nTW6b_6dNVM5vEfMKr4q1YVv4nJdcwZ38BNVSzlbvfmpcP99GfB4awbYMFrKqPKMbeTt0EElUf-F-4MbVqI-LKqat10eDjQjGYLIR4ptzrpc_4yBPu1/s1600/EXCEL_1.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;225&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi8ZsqmbpNsRYrQ4l73yP0ob01A4nTW6b_6dNVM5vEfMKr4q1YVv4nJdcwZ38BNVSzlbvfmpcP99GfB4awbYMFrKqPKMbeTt0EElUf-F-4MbVqI-LKqat10eDjQjGYLIR4ptzrpc_4yBPu1/s400/EXCEL_1.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
hard coded path of the files i have given must be changed ..&lt;br /&gt;
&lt;br /&gt;
i have declared the excel application and the workbook class globally&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt; Excel.ApplicationClass exApp; // Excel application&lt;br /&gt;
&amp;nbsp; Excel.Workbook exWb1; // first workbook&lt;br /&gt;
&amp;nbsp; Excel.Workbook exWb2; // second workbook&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
following commented block it will be easy to understand&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;exApp = new Excel.ApplicationClass(); // create application&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; exApp.Visible = false;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // making application invisible&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; exWb1 = exApp.Workbooks.Open(@&quot;D:\Book1.xlsx&quot;,Type.Missing,Type.Missing,Type.Missing,Type.Missing,Type.Missing,Type.Missing,Type.Missing,Type.Missing,Type.Missing,Type.Missing,Type.Missing,Type.Missing,Type.Missing,Type.Missing);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // open an workbook&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // i have given hard code path of the excel , but you must pass as variable &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // now we will add an excel workbook to our application and copy the first excel sheet to &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // second&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; exWb2 = exApp.Workbooks.Add(Type.Missing);&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // i will copy 1st into 2nd after the three by default sheets &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ((Excel.Worksheet)exWb1.Worksheets[1]).Copy(Type.Missing, exWb2.Worksheets[exWb2.Worksheets.Count]);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; exWb2.SaveAs(@&quot;D:\Copy_of_Book1.xlsx&quot;, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing,Excel.XlSaveAsAccessMode.xlNoChange, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // saving file path is also hard coded here you must change&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; exWb1.Close(0, null, null);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; exWb2.Close(0,null,null);&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; exApp.Quit(); // dont forget to quit the application&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
the copied excel looked like this&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjZkKnpLsgeEESuevEmVevFYdz-HppYU0Bb70IwR1VnGV_RLGd-gxOr6rfdsQflYK6CerWLNPeJfoKQmAgd-nuzMPkdHSyiDW4tqCxpLC5s6i7QlculyYDpXP8eI_81d9d2lCRoBLMykAiI/s1600/excel.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;350&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjZkKnpLsgeEESuevEmVevFYdz-HppYU0Bb70IwR1VnGV_RLGd-gxOr6rfdsQflYK6CerWLNPeJfoKQmAgd-nuzMPkdHSyiDW4tqCxpLC5s6i7QlculyYDpXP8eI_81d9d2lCRoBLMykAiI/s400/excel.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2) Suppose i have some value in the third row first column of the Book1 of the first picture , in how many ways i can retrieve the value ??&lt;br /&gt;
&lt;b style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; A) The easiest way using get range&amp;nbsp; &lt;/b&gt;:&lt;br /&gt;
&lt;b&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var _value = ((Excel.Worksheet)exWb1.Worksheets[1]).get_Range(&quot;A3&quot;, &quot;A3&quot;).Value2;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MessageBox.Show(_value.ToString());&lt;/b&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; B )&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/4035798040337059928/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/tips-and-tricks-on-manipulating-excel_11.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/4035798040337059928'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/4035798040337059928'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/tips-and-tricks-on-manipulating-excel_11.html' title='Tips and tricks on manipulating excel from codebehind in c# PART : 2'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi8ZsqmbpNsRYrQ4l73yP0ob01A4nTW6b_6dNVM5vEfMKr4q1YVv4nJdcwZ38BNVSzlbvfmpcP99GfB4awbYMFrKqPKMbeTt0EElUf-F-4MbVqI-LKqat10eDjQjGYLIR4ptzrpc_4yBPu1/s72-c/EXCEL_1.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-4081909506610683916</id><published>2011-10-10T11:08:00.000-07:00</published><updated>2011-10-10T11:08:42.250-07:00</updated><title type='text'>How to detect mouse right click or left click on windows form</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;Its easy to find which mouse button is been clicked , so first just double click on form&#39;s mouse click event and add the following code :&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;b&gt; private void Form1_MouseClick(object sender, MouseEventArgs e)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (e.Button == MouseButtons.Left)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MessageBox.Show(&quot;Left click&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (e.Button == MouseButtons.Right)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MessageBox.Show(&quot;Right click&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/b&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/4081909506610683916/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/how-to-detect-mouse-right-click-or-left.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/4081909506610683916'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/4081909506610683916'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/how-to-detect-mouse-right-click-or-left.html' title='How to detect mouse right click or left click on windows form'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-1019501687076173095</id><published>2011-10-10T07:27:00.000-07:00</published><updated>2011-10-10T10:56:12.188-07:00</updated><title type='text'>Tips and tricks on manipulating excel from codebehind in c# PART : 1</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;These days i am working so much with &lt;b&gt;Excel &lt;/b&gt;i felt a need to post those small &lt;b&gt;tricks &lt;/b&gt;in a listed manner , this will&amp;nbsp; have a several &lt;b&gt;part &lt;/b&gt;as &lt;b&gt;excel &lt;/b&gt;is a vast application probably one of my personal favorite product of &lt;b&gt;Microsoft&amp;nbsp; &lt;/b&gt;, i am starting with a base , to use the inbuilt classes of excel we need to first add the &lt;b&gt;&amp;nbsp;&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;1 ) Microsoft.Office.Interop.Excel&lt;/b&gt; dll from reference , the version is 12.0.0.0 is good and u will also have to add the namespace , same name .. but since it is so big and may be in application stage you may have some ambiguity so it is better to use an alias like&lt;br /&gt;
2) &lt;b&gt;using Excel&lt;/b&gt;=&lt;b&gt;Microsoft.Office.Interop.Excel&amp;nbsp; &lt;/b&gt;so from now we can use Excel to call all the methods first&lt;br /&gt;
we will create an excel application , we create a single application and work entirely on that , otherwise our process will slowdown&lt;br /&gt;
&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;div style=&quot;color: blue;&quot;&gt;Create ,&amp;nbsp;&lt;b&gt; excel application&lt;/b&gt; :&lt;/div&gt;&lt;b&gt;Excel.ApplicationClass exApp=new Excel.ApplicationClass();&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;exApp.Visible = true;&amp;nbsp;&lt;/b&gt; &lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;color: blue;&quot;&gt;Quit &lt;b&gt;Excel Application :&lt;/b&gt;&lt;/div&gt;&lt;b&gt;exApp.Quit();&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;color: blue;&quot;&gt;Add &lt;b&gt;Workbook &lt;/b&gt;with no template :&lt;/div&gt;&lt;b&gt;Excel.Workbook exWb1=exApp.Workbooks.Add(Type.Missing);&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;color: blue;&quot;&gt;Close &lt;b&gt;Workbook &lt;/b&gt;without saving and without showing any alert :&lt;/div&gt;&lt;b&gt;exWb1.Close(0, null, null);&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;color: blue;&quot;&gt;&lt;b&gt;Workbook &lt;/b&gt;by default contains three sheets .. if you want to add your own &lt;b&gt;sheet &lt;/b&gt;and name it before or after these sheets then do the following :&lt;/div&gt;Before :( suppose at the extreme left )&lt;br /&gt;
&lt;b&gt;exWb1.Worksheets.Add(exWb1.Worksheets[1], Type.Missing, Type.Missing, Type.Missing);&lt;br /&gt;
((Excel.Worksheet)exWb1.Worksheets[1]).Name = &quot;My sheet&quot;;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
After : (extreme right )&lt;br /&gt;
&lt;b&gt;exWb1.Worksheets.Add(Type.Missing, exWb1.Worksheets[exWb1.Worksheets.Count], Type.Missing, Type.Missing);&lt;br /&gt;
&amp;nbsp;((Excel.Worksheet)exWb1.Worksheets[exWb1.Worksheets.Count]).Name = &quot;My sheet&quot;;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Now lets delete any sheet&lt;br /&gt;
&lt;b&gt;((Excel.Worksheet)exWb1.Worksheets[1]).Delete();&lt;/b&gt;&lt;br /&gt;
delete the first sheet&lt;br /&gt;
but suppose i have 3 sheets and want to delete only the first three sheets then you cant simply repeat the above function twice more only changing the index for 2 and 3 .. you must try it and see what happens , i was once suffered from that problem&lt;br /&gt;
so to delete such sheets we need this , lets add two new sheets and delete the previous three sheets right !!&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;exWb1.Worksheets.Add(Type.Missing, exWb1.Worksheets[exWb1.Worksheets.Count],2, Type.Missing);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ((Excel.Worksheet)exWb1.Worksheets[exWb1.Worksheets.Count-1]).Name = &quot;My sheet1&quot;;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ((Excel.Worksheet)exWb1.Worksheets[exWb1.Worksheets.Count]).Name = &quot;My sheet2&quot;;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for (int i = 1; i &amp;lt;= 3; i++)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ((Excel.Worksheet)exWb1.Worksheets[1]).Delete();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
in the work sheet add method i have passed 2 in the parameter count , so that at a time two sheets added to the workbook&lt;br /&gt;
these samples may be familiar to you , but this is just the base and may be good for the beginners like me &lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/1019501687076173095/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/tips-and-tricks-on-manipulating-excel.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/1019501687076173095'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/1019501687076173095'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/tips-and-tricks-on-manipulating-excel.html' title='Tips and tricks on manipulating excel from codebehind in c# PART : 1'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-7652744343158646574</id><published>2011-10-04T04:54:00.000-07:00</published><updated>2011-10-04T04:58:17.548-07:00</updated><title type='text'>create a dynamic j-query an image scroller from a database images PART - 2</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;In the previous article of the &lt;b&gt;dynamic image scroller&lt;/b&gt; &amp;nbsp; i wrote the html part of the application .. no i will write the code behind section .. first part we will fetch the active images order by their position ascending ... we add a &lt;b&gt;linq to sql class&lt;/b&gt; from &quot;add new item&quot; and drag our table into the&lt;b&gt; linq to sql class&lt;/b&gt; .. whole my project now look like this&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhXOcFwDYNl_AguZtZg2B2AzpvuPSLjWcUNEGseDu-0GVaYjoNrmABX68UmiP6_VPTNkj0PP-TPaGHjclpuBpjda0VEEsqUVp-VYon3Kr_12crbciGPkNPRJsiBjMCHrovKUwR9DBFL0Jpc/s1600/untitled.PNG&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;250&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhXOcFwDYNl_AguZtZg2B2AzpvuPSLjWcUNEGseDu-0GVaYjoNrmABX68UmiP6_VPTNkj0PP-TPaGHjclpuBpjda0VEEsqUVp-VYon3Kr_12crbciGPkNPRJsiBjMCHrovKUwR9DBFL0Jpc/s400/untitled.PNG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;you can see the database at left side server explorer and the project file at right hand side in the solution explorer&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b style=&quot;color: blue;&quot;&gt;&amp;nbsp; protected void imageAlbum()&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; #region fetch the result set into images&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DataClassesDataContext _dataBase = new DataClassesDataContext();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var images = from tbl in _dataBase.TBL_IMAGEs&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; where tbl.ACTIVE_FLAG == 1&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; orderby tbl.IMAGE_POSITION ascending&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; select new { imageName = tbl.IMAGE_NAME };&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; #endregion&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; #region create the html tag &lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HtmlGenericControl dvMain = new HtmlGenericControl(&quot;div&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dvMain.Attributes.Add(&quot;id&quot;, &quot;gallery&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HtmlGenericControl ulMain = new HtmlGenericControl(&quot;ul&quot;);&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; foreach (var image in images)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HtmlGenericControl li = new HtmlGenericControl(&quot;li&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HtmlAnchor a = new HtmlAnchor();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; a.HRef = @&quot;~\photos\&quot; + image.imageName + &quot;.jpg&quot;;&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HtmlImage img = new HtmlImage();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; img.Height = 72;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; img.Width = 72;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; img.Src = @&quot;~\photos\&quot; + &quot;thumb_&quot; + image.imageName + &quot;.jpg&quot;;&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; a.Controls.Add(img);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; li.Controls.Add(a);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ulMain.Controls.Add(li);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dvMain.Controls.Add(ulMain);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; image_container.Controls.Add(dvMain);&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; #endregion&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
call this function in the pageload section .. &lt;br /&gt;
you will understand how it works if you compare the html part from the html file you download in &lt;b&gt;jquery &lt;/b&gt;site and how i created them &lt;b&gt;from code behind &lt;/b&gt;.. as they both are the same ...&lt;br /&gt;
&lt;br /&gt;
run this ... for any problem ask me ... if you want to&amp;nbsp; add a title to each image then just add a column title to database .. fetch the value and add to the anchor element &quot;a&quot; as the title attribute ...&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/7652744343158646574/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/create-dynamic-j-query-image-scroller_04.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/7652744343158646574'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/7652744343158646574'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/create-dynamic-j-query-image-scroller_04.html' title='create a dynamic j-query an image scroller from a database images PART - 2'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhXOcFwDYNl_AguZtZg2B2AzpvuPSLjWcUNEGseDu-0GVaYjoNrmABX68UmiP6_VPTNkj0PP-TPaGHjclpuBpjda0VEEsqUVp-VYon3Kr_12crbciGPkNPRJsiBjMCHrovKUwR9DBFL0Jpc/s72-c/untitled.PNG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-6192500542634552636</id><published>2011-10-03T19:11:00.000-07:00</published><updated>2011-10-04T04:55:37.887-07:00</updated><title type='text'>create a dynamic j-query an image scroller from a database images PART - 1</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;We often use j query in our websites to make it look gorgeous .. but most&amp;nbsp; of the time you see them they are basically static .. ie suppose there is an image scroller like this&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;http://leandrovieira.com/projects/jquery/lightbox/&quot;&gt;http://leandrovieira.com/projects/jquery/lightbox/&lt;/a&gt;&lt;br /&gt;
you can download the whole package from here ... &lt;br /&gt;
&lt;br /&gt;
but in this , our images are static that is every time you need to change the position or change the image itself you will have do it from the html which is very much hazardous ... so it dynamic website we need to make it dynamic .. we will have an image database an any change on it will reflect in the image scroller in our website ...&amp;nbsp; for this what we need most is the use of namespaces&amp;nbsp; are&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;using System.Web.UI.HtmlControls;&lt;/span&gt; // for creating&amp;nbsp; the html controls &lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;using System.Xml.Linq; &amp;nbsp; &amp;nbsp; &lt;span style=&quot;color: black;&quot;&gt;// i am gonna work on database using linq&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
after downloading the package you will find some folders &lt;b&gt;css , images , js , photos&amp;nbsp; &lt;/b&gt;and the &lt;b&gt;html &lt;/b&gt;page , other than html we will copy all the folder and paste to the solution explorer of&amp;nbsp; our website as we have no work there , they will work on their own&lt;br /&gt;
in the photos folder you will see two image one big and one thumb (small) ie when you create thumb it zoom , the zoom image is nothing but the bigger version of the thumbnail , now we will create the image database&lt;br /&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: red; font-size: small;&quot;&gt;CREATE TABLE [dbo].[TBL_IMAGE](&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; [IMAGE_ID] [int] IDENTITY(1,1) NOT NULL,&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; [IMAGE_NAME] [nvarchar](50) NULL,&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; [IMAGE_POSITION] [int] NULL,&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; [ACTIVE_FLAG] [tinyint] NULL,&lt;br /&gt;
&amp;nbsp;CONSTRAINT [PK_TBL_IMAGE] PRIMARY KEY CLUSTERED &lt;br /&gt;
(&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; [IMAGE_ID] ASC&lt;br /&gt;
)WITH (PAD_INDEX&amp;nbsp; = OFF, STATISTICS_NORECOMPUTE&amp;nbsp; = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS&amp;nbsp; = ON, ALLOW_PAGE_LOCKS&amp;nbsp; = ON) ON [PRIMARY]&lt;br /&gt;
) ON [PRIMARY]&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
and the insert the image name ( you can create your panel for inserting those image into the database )&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: red;&quot;&gt;INSERT INTO [TBL_IMAGE] VALUES (&#39;image1&#39;,1,1)&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: red;&quot;&gt;INSERT INTO [TBL_IMAGE] VALUES (&#39;image2&#39;,2,1)&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: red;&quot;&gt;INSERT INTO [TBL_IMAGE] VALUES (&#39;image3&#39;,3,1)&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: red;&quot;&gt;INSERT INTO [TBL_IMAGE] VALUES (&#39;image4&#39;,4,1)&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: red;&quot;&gt;INSERT INTO [TBL_IMAGE] VALUES (&#39;image5&#39;,5,1)&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
now in our&amp;nbsp; aspx.cs page we will have two region , one inner and one outer ..&lt;br /&gt;
in the outer region we will fetch data and in the inner region we will generate all the required html tages dynamically first drag all the required css and js file in the title section&lt;br /&gt;
&lt;br /&gt;
so then our aspx page title will conatain these tags :&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;lt;script type=&quot;text/javascript&quot; src=&quot;js/jquery.js&quot;&amp;gt;&amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;script type=&quot;text/javascript&quot; src=&quot;js/jquery.lightbox-0.5.js&quot;&amp;gt;&amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;link rel=&quot;stylesheet&quot; type=&quot;text/css&quot; href=&quot;css/jquery.lightbox-0.5.css&quot; media=&quot;screen&quot; /&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;script type=&quot;text/javascript&quot;&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; $(function() {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; $(&#39;#gallery a&#39;).lightBox();&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; });&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/script&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;style type=&quot;text/css&quot;&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* jQuery lightBox plugin - Gallery style */&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; #gallery {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; background-color: #444;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; padding: 10px;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; width: 520px;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; #gallery ul { list-style: none; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; #gallery ul li { display: inline; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; #gallery ul img {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; border: 5px solid #3e3e3e;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; border-width: 5px 5px 20px;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; #gallery ul a:hover img {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; border: 5px solid #fff;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; border-width: 5px 5px 20px;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; color: #fff;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; #gallery ul a:hover { color: #fff; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/style&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
in the body section we will create a div and make it dynamic so that we can access it from code behind .&amp;nbsp; it will be our html code container .. tag looks like this :&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;lt;div id=&quot;image_container&quot; runat=&quot;server&quot;&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/div&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
the next code behind part is on part 2 of this article . Read part 2 : &lt;i&gt;&lt;b&gt;&lt;a href=&quot;http://mynecessarycode.blogspot.com/2011/10/create-dynamic-j-query-image-scroller_04.html&quot;&gt;PART 2&lt;/a&gt;&lt;/b&gt;&lt;/i&gt;&lt;br /&gt;
Continued .. &lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/6192500542634552636/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/create-dynamic-j-query-image-scroller.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/6192500542634552636'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/6192500542634552636'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/10/create-dynamic-j-query-image-scroller.html' title='create a dynamic j-query an image scroller from a database images PART - 1'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-6160294100921758440</id><published>2011-09-27T11:45:00.000-07:00</published><updated>2011-09-27T11:45:50.791-07:00</updated><title type='text'>Create a method for fetching data into a dataset using any stored procedure with any nos of parameters</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;A few days ago before i started work with &lt;b&gt;entity data model and linq&lt;/b&gt; i worked with dataset a lot .. there i had to work with something like , i will create method to &lt;b&gt;fetch data into dataset&lt;/b&gt;&amp;nbsp; , ie i call it form other class i will simply pass the &lt;b&gt;Stored procedure&lt;/b&gt; name and add the &lt;b&gt;parameters&lt;/b&gt; .. that&#39;s all&amp;nbsp; , so i had written the method in my &lt;b&gt;base class and call it from the business layer&lt;/b&gt; .. that&#39;s way&amp;nbsp; it add security to my application&lt;br /&gt;
Now the code for the base class was :&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue; font-size: small;&quot;&gt;&amp;nbsp;public DataSet FillDataSetUsingSP(SqlParameterCollection sql_param_col ,string sp_name)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DataSet ds = new DataSet();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ConOpen(); &lt;b&gt;&lt;span style=&quot;color: #38761d;&quot;&gt;// you must create the conopen method for opening the connection object&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; SqlCommand cmd = new SqlCommand(sp_name,con);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cmd.CommandType = CommandType.StoredProcedure;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; foreach (SqlParameter pm in sql_param_col)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cmd.Parameters.AddWithValue(pm.ParameterName, pm.Value);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SqlDataAdapter da = new SqlDataAdapter(cmd);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; da.Fill(ds);&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return ds;&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
so here our &lt;b&gt;method &lt;/b&gt;is ready and we will call it in this way ..&lt;br /&gt;
&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;ENTERPRISE_CLS encls = new ENTERPRISE_CLS(); // my base class name was ENTERPRISE_CLS&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; public BUSINESS_ACCESS()&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; //&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // TODO: Add constructor logic here&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; //&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; public DataSet Return_Data(string p, string q)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SqlParameterCollection spc = new SqlCommand().Parameters;&amp;nbsp;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; spc.AddWithValue(&quot;@news_hdr&quot;, p);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; spc.AddWithValue(&quot;@news_lnk&quot;, q);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DataSet ds = encls.FillDataSetUsingSP(spc, &quot;retrieve_news_letter&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return ds;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
we use &lt;b&gt;&lt;span style=&quot;color: blue;&quot;&gt;SqlParameterCollection spc = new SqlCommand().Parameters;&lt;/span&gt;&amp;nbsp;&lt;/b&gt;&lt;br /&gt;
&amp;nbsp;to create the &lt;b&gt;parameter collection&lt;/b&gt; and pass it , our &lt;b&gt;stored procedure&lt;/b&gt; name is &lt;b&gt;&lt;span style=&quot;color: blue;&quot;&gt;&quot;retrieve_news_letter&quot;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
so if you have any query regarding this you can ask , i will soon create this for &lt;b&gt;linq&lt;/b&gt; ...&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/6160294100921758440/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/create-method-for-fetching-data-into.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/6160294100921758440'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/6160294100921758440'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/create-method-for-fetching-data-into.html' title='Create a method for fetching data into a dataset using any stored procedure with any nos of parameters'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-1466970613107229644</id><published>2011-09-26T08:45:00.000-07:00</published><updated>2011-09-26T08:45:47.198-07:00</updated><title type='text'>Use one stored procedure inside PL/SQL block of another stored procedure</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;You now how to use a &lt;b&gt;stored procedure&lt;/b&gt; , i am just showing you how to use the result of &lt;b&gt;one stored procedure&lt;/b&gt; inside another ... first i am creating a category and a subcategory .. one subcategory must have a category as parent .. i will&amp;nbsp; simply&amp;nbsp; use one &lt;b&gt;stored procedure&lt;/b&gt; and i&amp;nbsp; will also check whether the category exists or not .&lt;br /&gt;
&lt;br /&gt;
the two code for creating two tables are :&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: red;&quot;&gt;CREATE TABLE [dbo].[CATAGORY](&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [CAT_ID] [int] IDENTITY(1,1) NOT NULL,&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [CAT_NAME] [varchar](50) NULL&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;) ON [PRIMARY]&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;and&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: red; font-size: x-small;&quot;&gt;CREATE TABLE [dbo].[SUB_CATAGORY](&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; [SUB_CAT_ID] [int] NOT NULL,&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; [CAT_ID] [int] NULL,&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; [SUB_CAT_NAME] [varchar](50) NULL&lt;br /&gt;
) ON [PRIMARY]&lt;/span&gt; &lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
Enter some values&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: red;&quot;&gt;INSERT INTO dbo.CATAGORY (CAT_NAME) VALUES (&#39;INDIA&#39;)&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;INSERT INTO dbo.CATAGORY (CAT_NAME) VALUES (&#39;AMERICA&#39;)&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;INSERT INTO dbo.CATAGORY (CAT_NAME) VALUES (&#39;CHINA&#39;)&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;INSERT INTO dbo.CATAGORY (CAT_NAME) VALUES (&#39;EUROPE&#39;)&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
Now i create a procedure that will get category name as input and result the category id in a out parameter&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: red; font-size: x-small;&quot;&gt;CREATE PROCEDURE SP_GET_CAT_ID&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; @CAT_ID INT OUTPUT,&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; @CAT_NAME VARCHAR(50)&lt;br /&gt;
AS BEGIN &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; SELECT @CAT_ID=CAT_ID FROM dbo.CATAGORY WHERE CAT_NAME=@CAT_NAME&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; PRINT @CAT_ID&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; END&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;[ here i have simply get the category id inside the output parameter]&lt;/span&gt;&lt;br /&gt;
you can execute the query and see the result by the following query&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: red; font-size: x-small;&quot;&gt;DECLARE @CAT_OUT INT&lt;br /&gt;
EXEC SP_GET_CAT_ID @CAT_OUT,&#39;INDIA&#39;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
now i will use this stored procedure inside a new stored procedure&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: red; font-size: x-small;&quot;&gt;CREATE &lt;/span&gt;&lt;span style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: red;&quot;&gt;PROCEDURE SP_INSERT_SUBCATEGORY&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @CAT_NAME VARCHAR(50),&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @SUB_CAT_NAME VARCHAR(50)&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;AS BEGIN&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; DECLARE @CAT_ID INT&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; -- GET THE CATEGORY ID FROM PREVIOUS STORED PROCEDUTE INTO&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; -- THE VARIABLE @CAT_ID&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; EXEC SP_GET_CAT_ID @CAT_ID OUTPUT,@CAT_NAME&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; -- CHECKING IF THE RETURN VALUE EXISTS THAT IS NULL&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; IF @CAT_ID IS NOT NULL&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; INSERT INTO dbo.SUB_CATAGORY (CAT_ID,SUB_CAT_NAME) VALUES (@CAT_ID,@SUB_CAT_NAME)&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ELSE&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; PRINT &#39; NO SUCH CATEGORY EXISTS THERE !!!&#39;&lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;br style=&quot;color: red;&quot; /&gt;&lt;span style=&quot;color: red;&quot;&gt;END&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: blue;&quot;&gt;CHECK THE PROCEDURE BY EXECUTING&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: red;&quot;&gt;SP_INSERT_SUBCATEGORY &#39;AMERICA&#39;,&#39;WISCONSIN&#39;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;for an other value that does not belong to the category table you will get the error message .. . so you find it very secure because when you will need to add a sub category under a category you dont need much to write in code just call the second stored procedure ..&lt;/span&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/1466970613107229644/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/use-one-stored-procedure-inside-plsql.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/1466970613107229644'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/1466970613107229644'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/use-one-stored-procedure-inside-plsql.html' title='Use one stored procedure inside PL/SQL block of another stored procedure'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-5827777577086102304</id><published>2011-09-21T08:13:00.000-07:00</published><updated>2011-09-21T08:13:08.593-07:00</updated><title type='text'>Problem with *Result and *Result Specified parameters in WCF service</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;There is a common problem in &lt;b&gt;wcf&amp;nbsp; &lt;/b&gt;that you have two extra parameters &lt;b style=&quot;color: blue;&quot;&gt;*Result and *Result Specified &lt;/b&gt;while invoking the methods .. this means that the serialization&amp;nbsp; format is not done .. so for this you simply need to add or replace the following code above your IService Interface :&lt;br /&gt;
&lt;br /&gt;
&lt;b style=&quot;color: blue;&quot;&gt;[ServiceContract ( Namespace=&quot;http://www.yoursite.com/&quot;),XmlSerializerFormat]&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
if you have already add the service to your IIS and create reference to your website then dont worry&amp;nbsp; , simply do the following steps:&lt;br /&gt;
1) rebuild the service library &lt;br /&gt;
2)delete the previously added DLL file to your service website and add the rebuild dll&amp;nbsp; , save the changes &lt;br /&gt;
3) the IIS will automatically reconfigure it since it is mapped to the file&lt;br /&gt;
4)in your application where you have referenced the service simply right click on &lt;b&gt;App_WebReferences&lt;/b&gt; folder and click &lt;b&gt;&quot;Update Web/Service Reference&quot;&lt;/b&gt; and the problem is solved , call the methods and no problem arise ...&lt;br /&gt;
&lt;br /&gt;
thank you ...&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/5827777577086102304/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/problem-with-result-and-result.html#comment-form' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/5827777577086102304'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/5827777577086102304'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/problem-with-result-and-result.html' title='Problem with *Result and *Result Specified parameters in WCF service'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-2835903395326637585</id><published>2011-09-21T07:51:00.000-07:00</published><updated>2011-09-21T08:16:18.559-07:00</updated><title type='text'>Calling WCF  Service Hosted in IIS and invoke the methods</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;So far we have created a &lt;b&gt;service &lt;/b&gt;and hosted the &lt;b&gt;service &lt;/b&gt;in the IIS of our computer .. if you are straight to this page and want to view those article the you can go through the following links :&lt;br /&gt;
&lt;b&gt;&lt;a href=&quot;http://mynecessarycode.blogspot.com/2011/09/simple-login-control-using-wcf-service.html&quot;&gt;Part : 1&lt;/a&gt;&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;&lt;a href=&quot;http://mynecessarycode.blogspot.com/2011/09/simple-login-control-using-wcf-service_18.html&quot;&gt;Part : 2&lt;/a&gt;&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;&lt;a href=&quot;http://mynecessarycode.blogspot.com/2011/09/part-3-host-wcf-application-in-iis.html&quot;&gt;Part : 3&lt;/a&gt;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
now our &lt;b&gt;service &lt;/b&gt;url is &lt;b&gt;&quot;http://localhost/RegIIS/Service.svc&quot;&lt;/b&gt; and if we run this in our browser ( i.e. simply copy and paste in the address bar ) then we will see the following&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjSfTsqqRQ8oENrKy8eyDEcsofik2qoo8teTaCFNEIr6Dn-kJz5hmj0Fh1Iap6nutQeE69jgGmadccaFIVJW3vFpy5e_S7GAwtn3wXyha33h7qy-1E241OQx9in_izKX-XBI2DCGKRszjOu/s1600/cats4.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;250&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjSfTsqqRQ8oENrKy8eyDEcsofik2qoo8teTaCFNEIr6Dn-kJz5hmj0Fh1Iap6nutQeE69jgGmadccaFIVJW3vFpy5e_S7GAwtn3wXyha33h7qy-1E241OQx9in_izKX-XBI2DCGKRszjOu/s400/cats4.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgvkl3nYnWSeQ1rq1VT7ScgCKl9ZUBBiD5YAfFyIPOCkdTWObnpKuveysLFrbi35x3xQ2Gig-iMhQ8Ak9pmUKF26jHChPVa6b8aW4u1TuBveL3mBJvQtvSEDYOJ9SB0jHHgNZdCh9TiLO8P/s1600/cats.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;br /&gt;
&lt;/a&gt;&lt;/div&gt;Our &lt;b&gt;service &lt;/b&gt;has two Boolean methods&lt;br /&gt;
1) login , 2) registration&lt;br /&gt;
so we will invoke them from our application ... so for that first create a website , and create a form for log in as i am going to explain for log in , if you understand it you can invoke the method registration easily &lt;br /&gt;
&lt;br /&gt;
i have created a form have two text boxes for user id and password , one log in button , and a label to show the message ... my form looks like this ,,&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgCfp2sHUUuuX1kvEMO9RNzXdSP1N8F9SFQxaBeg8YO4AwF6BiNo1JmZz3HJUY40JHNeswhMXSouQZ7mcpOh1HkNk5RAgAS1ykGPiveNjFIBe724IFRBl83r0yV5I-127NnfzqD-_iYCH6s/s1600/cats3.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;191&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgCfp2sHUUuuX1kvEMO9RNzXdSP1N8F9SFQxaBeg8YO4AwF6BiNo1JmZz3HJUY40JHNeswhMXSouQZ7mcpOh1HkNk5RAgAS1ykGPiveNjFIBe724IFRBl83r0yV5I-127NnfzqD-_iYCH6s/s320/cats3.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;its not that good to look , make your own &lt;br /&gt;
log in and registration form ...&lt;br /&gt;
&lt;br /&gt;
Now we will add the service reference to our website ,&lt;br /&gt;
for this right click on your solution explorer , click on &quot;Add Web Reference&quot; , in the opened window paste the service URL you have and hit &quot;Go&quot; ..&lt;br /&gt;
it will search the service and find it .. give a name to your namespace&amp;nbsp; as we will need it later ..&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgvkl3nYnWSeQ1rq1VT7ScgCKl9ZUBBiD5YAfFyIPOCkdTWObnpKuveysLFrbi35x3xQ2Gig-iMhQ8Ak9pmUKF26jHChPVa6b8aW4u1TuBveL3mBJvQtvSEDYOJ9SB0jHHgNZdCh9TiLO8P/s1600/cats.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;262&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgvkl3nYnWSeQ1rq1VT7ScgCKl9ZUBBiD5YAfFyIPOCkdTWObnpKuveysLFrbi35x3xQ2Gig-iMhQ8Ak9pmUKF26jHChPVa6b8aW4u1TuBveL3mBJvQtvSEDYOJ9SB0jHHgNZdCh9TiLO8P/s400/cats.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
I have given &quot;RegestrationIIS&quot; , now click Add Reference it will add all the file and folder structure to you solution ..&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgywGSo4fjRgpDFiMvndYUZbsstjjV7W8rKXQtIWDTNT69L72hSZFPmiNMKC0_MSFZsM4bdWxsHo6antawCTNE3qWdRuKSQmtvdEgE_QkX6u3oPFgYK6ub5bHqVEwCe0JJauiv1YRxsnJ6r/s1600/cats2.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgywGSo4fjRgpDFiMvndYUZbsstjjV7W8rKXQtIWDTNT69L72hSZFPmiNMKC0_MSFZsM4bdWxsHo6antawCTNE3qWdRuKSQmtvdEgE_QkX6u3oPFgYK6ub5bHqVEwCe0JJauiv1YRxsnJ6r/s320/cats2.jpg&quot; width=&quot;186&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
see the App_WebReference folder has been added automatically ..&lt;br /&gt;
now in our code behind we will add the namespace by calling it&lt;br /&gt;
&lt;br /&gt;
&lt;b style=&quot;color: blue;&quot;&gt;using RegestrationIIS;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
then we will create an instance of our class Service1 &lt;i&gt;( for good practice you should give proper name to your class )&lt;/i&gt;&lt;br /&gt;
RegestrationIIS.&lt;span style=&quot;color: #38761d;&quot;&gt;Service1 &lt;/span&gt;_service = &lt;span style=&quot;color: blue;&quot;&gt;new &lt;/span&gt;RegestrationIIS.&lt;span style=&quot;color: #6aa84f;&quot;&gt;Service1&lt;/span&gt;();&lt;br /&gt;
&lt;br /&gt;
in our button click event i have declared a Boolean variable &lt;b&gt;&quot;result&quot;&amp;nbsp; &lt;/b&gt;that holds the result of login&lt;br /&gt;
we can call the method now&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;bool result = _service.login(txt_user_id.Text, txt_pwd.Text);&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;(you can probably have an&amp;nbsp; error of two extra parameters result and result specified parameters you can solve them by reading my following article)&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;b&gt;&lt;a href=&quot;http://mynecessarycode.blogspot.com/2011/09/problem-with-result-and-result.html&quot;&gt;Click here to read the article&lt;/a&gt;&lt;/b&gt;&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
if it returns true the successful login else there is an error&amp;nbsp; &lt;span style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;so the full and final code goes like this :&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: blue;&quot;&gt;using System;&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;using System.Configuration;&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;using System.Data;&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;using RegestrationIIS;&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;public partial class _Default : System.Web.UI.Page &lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;{&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; RegestrationIIS.Service1 _service = new RegestrationIIS.Service1();&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; protected void Page_Load(object sender, EventArgs e)&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; protected void btnlogin_Click(object sender, EventArgs e)&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; bool result = _service.login(txt_user_id.Text, txt_pwd.Text);&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (result)&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; lblerror.Text = &quot;Log in successfully&quot;;&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; else&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; lblerror.Text = &quot;Error occurred .. try again&quot;;&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; txt_pwd.Text = &quot;&quot;;&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br style=&quot;color: blue;&quot; /&gt;&lt;span style=&quot;color: blue;&quot;&gt;}&lt;/span&gt;&lt;/b&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
so we have successfully invoke the methods of our &lt;b&gt;WCF &lt;/b&gt;Service hosted in &lt;b&gt;IIS &lt;/b&gt;in our website ... if there is any problem to understand anywhere you can post or email me at &lt;span style=&quot;background-color: #f3f3f3; color: blue;&quot;&gt;somabrata.roy1986@gmail.com&lt;/span&gt; ...&lt;br /&gt;
&lt;br /&gt;
thank you now .. &lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/2835903395326637585/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/calling-wcf-hosted-in-iis-and-invoke.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/2835903395326637585'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/2835903395326637585'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/calling-wcf-hosted-in-iis-and-invoke.html' title='Calling WCF  Service Hosted in IIS and invoke the methods'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjSfTsqqRQ8oENrKy8eyDEcsofik2qoo8teTaCFNEIr6Dn-kJz5hmj0Fh1Iap6nutQeE69jgGmadccaFIVJW3vFpy5e_S7GAwtn3wXyha33h7qy-1E241OQx9in_izKX-XBI2DCGKRszjOu/s72-c/cats4.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-2934452603796677943</id><published>2011-09-21T05:57:00.000-07:00</published><updated>2011-09-21T05:57:33.092-07:00</updated><title type='text'>Format and return all the texts  from a website according to your neded pattern</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;In my earlier blog post &lt;a href=&quot;http://mynecessarycode.blogspot.com/2011/09/download-all-images-from-web-url.html&quot;&gt;Click here to view my post&lt;/a&gt; I have mentioned a method &lt;span style=&quot;color: blue;&quot;&gt;DownloadString(string Url)&amp;nbsp; &amp;nbsp; &lt;span style=&quot;color: black;&quot;&gt;which i have used to download all the contents from a web page , but to search a specific type of URL i had to format those texts because they were pretty haphazard and non-arranged&amp;nbsp; , its like i need to wrap them up with&lt;/span&gt; &lt;span style=&quot;color: black;&quot;&gt;my search pattern , i wanted to rearrange them with&lt;span style=&quot;color: blue;&quot;&gt;&quot;&amp;lt;img &quot;&lt;/span&gt;&lt;/span&gt;&amp;nbsp; &lt;span style=&quot;color: black;&quot;&gt;tag as i had to get all the strings that contains &lt;span style=&quot;color: blue;&quot;&gt;&quot;&amp;lt;img src&quot;&lt;/span&gt;&lt;/span&gt; &lt;span style=&quot;color: black;&quot;&gt;tag&lt;/span&gt; &lt;span style=&quot;color: black;&quot;&gt;, so my code here was :&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;suppose i have a string variable&lt;span style=&quot;color: blue;&quot;&gt; &lt;b&gt;&quot;string body&quot;&lt;/b&gt; &lt;/span&gt;that containsall the text of the web page &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;color: blue;&quot;&gt;&lt;b&gt;string[] stringSeparators = new string[] { &quot;&amp;lt;img&quot; };&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;b&gt;&amp;nbsp;string[] _str_arr = body.Split(stringSeparators, StringSplitOptions.RemoveEmptyEntries);&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;b&gt;&amp;nbsp;&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;b&gt;&amp;nbsp;&lt;/b&gt;&lt;span style=&quot;color: black;&quot;&gt;the first line declares a string array holds all search of match pattern &quot;&lt;/span&gt;&lt;b&gt;stringSeparators &lt;/b&gt;&lt;span style=&quot;color: black;&quot;&gt;&quot;&lt;/span&gt;&lt;b&gt; &lt;/b&gt;&lt;/div&gt;&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&amp;nbsp;in the next i have split the full&amp;nbsp; string with the pattern with a &lt;span style=&quot;color: blue;&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;b style=&quot;color: blue;&quot;&gt;StringSplitOptions.RemoveEmptyEntries&quot;&amp;nbsp;&lt;/b&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;with which a have rejected all those strings that have return a null string or not matched to my pattern &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;watch carefully&amp;nbsp; the following images &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhQdR1hy3F00HTyhgKfWi_dcum11ke0hWjXkd-PKF8VR0eSKkaqtXC8Kuz8O8Jmdz26xUS1NIZ9cMuicyO_dWZc2l5hAFHCWU9E_B2qZZpG6jPHCB9VzdYAi1Y3uliPPSmAS9z9s4Tn6Ra1/s1600/untitled.PNG&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;250&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhQdR1hy3F00HTyhgKfWi_dcum11ke0hWjXkd-PKF8VR0eSKkaqtXC8Kuz8O8Jmdz26xUS1NIZ9cMuicyO_dWZc2l5hAFHCWU9E_B2qZZpG6jPHCB9VzdYAi1Y3uliPPSmAS9z9s4Tn6Ra1/s400/untitled.PNG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;b&gt;&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;click the image link to see it bigger ,&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;anyway you can see that it returns an array&amp;nbsp; with all element starting with &quot;src&quot; , obviously they are started with &quot;&amp;lt;img&quot; and they are all the image links ...&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;so that&#39;s it we get what we want&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;if you find it helpful or get any query please post comment here ..&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;thank you&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/2934452603796677943/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/format-and-return-all-texts-from.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/2934452603796677943'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/2934452603796677943'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/format-and-return-all-texts-from.html' title='Format and return all the texts  from a website according to your neded pattern'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhQdR1hy3F00HTyhgKfWi_dcum11ke0hWjXkd-PKF8VR0eSKkaqtXC8Kuz8O8Jmdz26xUS1NIZ9cMuicyO_dWZc2l5hAFHCWU9E_B2qZZpG6jPHCB9VzdYAi1Y3uliPPSmAS9z9s4Tn6Ra1/s72-c/untitled.PNG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-882581158212666099</id><published>2011-09-20T03:01:00.000-07:00</published><updated>2011-09-20T11:13:12.367-07:00</updated><title type='text'>Download all images from a web URL</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&amp;nbsp;&lt;b&gt;This is me demonstrating an application where you will get all the images from a web URL , and you can download them at once in a zip format ,&amp;nbsp; this is an application in process ,,, i have some of the functions i have used and i have written , i will modify this code to 100% accuracy soon till then you can try and work with this methods&amp;nbsp;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;I am adding an image of the application so that you understand it&amp;nbsp;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEis8PxKBHKRhs_ed-3RKvqUHDSSl5fso_kfh5oPD-i5JDDJcDhMksstobaZUpHy6pwJbKl4cwyBcMwHj5LUyXlfh2UWUTekOKAJipA4mf6sNsHgkbe80gzoEJ30_4up_y68Fn0Xd-JFb9VT/s1600/url_to_img.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;250&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEis8PxKBHKRhs_ed-3RKvqUHDSSl5fso_kfh5oPD-i5JDDJcDhMksstobaZUpHy6pwJbKl4cwyBcMwHj5LUyXlfh2UWUTekOKAJipA4mf6sNsHgkbe80gzoEJ30_4up_y68Fn0Xd-JFb9VT/s400/url_to_img.PNG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; static int count = 1;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; static int image_count = 0;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; private string DownloadString(string Url)&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Open a connection&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HttpWebRequest WebRequestObject = (HttpWebRequest)HttpWebRequest.Create(Url);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // You can also specify additional header values like &lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // the user agent or the referer:&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; WebRequestObject.UserAgent = &quot;.NET Framework/2.0&quot;;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; WebRequestObject.Referer = &quot;http://www.example.com/&quot;;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Request response:&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; WebResponse Response = WebRequestObject.GetResponse();&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Open data stream:&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Stream WebStream = Response.GetResponseStream();&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Create reader object:&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; StreamReader Reader = new StreamReader(WebStream);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Read the entire stream content:&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string PageContent = Reader.ReadToEnd();&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Cleanup&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Reader.Close();&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; WebStream.Close();&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Response.Close();&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; txtcontent.Text = PageContent;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return PageContent;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; private void ReaDImageTag(string body)&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; try&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string web_url = getUrl(txturl.Text);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string[] stringSeparators = new string[] { &quot;&amp;lt;img&quot; };&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string[] _str_arr = body.Split(stringSeparators, StringSplitOptions.RemoveEmptyEntries);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string final_go_to_url = &quot;&quot;;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ArrayList _str_url = new ArrayList();&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for (int i = 1; i &amp;lt; _str_arr.Count(); i++)&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string p = _str_arr.ElementAt(i).ToString();&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (p.Contains(&quot;src=&quot;))&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string q = Regex.Replace(p, &quot;[\n\r\t]&quot;, &quot; &quot;);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; int start_index = q.IndexOf(&quot;src=&quot;);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; int start_index_mod = start_index + 5;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string str_url = q.Substring(start_index_mod, 100);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; int f_occr_of_invertd_com = str_url.IndexOf(&#39;&quot;&#39;,start_index_mod+1);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string finalUrl = str_url.Substring(0, f_occr_of_invertd_com);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (finalUrl.StartsWith(&quot;http://&quot;))&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; final_go_to_url = finalUrl;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; else&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (finalUrl.StartsWith(@&quot;/&quot;))&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; final_go_to_url = web_url + finalUrl;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; else&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; final_go_to_url = web_url + @&quot;/&quot; + finalUrl;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HtmlAnchor ha = new HtmlAnchor();&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HtmlImage img = new HtmlImage();&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; img.Src = final_go_to_url;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; img.Height = 100;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; img.Width = 100;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ha.HRef = final_go_to_url;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ha.Target = &quot;_blank&quot;;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HtmlGenericControl br = new HtmlGenericControl(&quot;br&quot;);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ha.Controls.Add(img);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; div_link.Controls.Add(ha);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; div_link.Controls.Add(br);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; count = count + 1;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; image_count = image_count + 1;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; lblcount.Text = &quot;Images found in the url&quot; + &quot; &quot; + image_count.ToString();&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; catch (Exception ex)&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Response.Write(ex.Message.ToString());&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; private string getUrl(string url)&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string host_name = &quot;&quot;;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string[] array_host = new string[] { &quot;.com&quot;,&quot;.co.in&quot;,&quot;.net&quot;,&quot;.org&quot;,&quot;.co.uk&quot;};&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for (int i = 0; i &amp;lt; array_host.Count(); i++)&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (url.Contains(array_host[i].ToString()))&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; host_name = array_host[i].ToString();&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; break;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; else&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; int index = url.LastIndexOf(host_name);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string str_url = url.Substring(0, index + host_name.Length);&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return str_url;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;}&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/882581158212666099/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/download-all-images-from-web-url.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/882581158212666099'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/882581158212666099'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/download-all-images-from-web-url.html' title='Download all images from a web URL'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEis8PxKBHKRhs_ed-3RKvqUHDSSl5fso_kfh5oPD-i5JDDJcDhMksstobaZUpHy6pwJbKl4cwyBcMwHj5LUyXlfh2UWUTekOKAJipA4mf6sNsHgkbe80gzoEJ30_4up_y68Fn0Xd-JFb9VT/s72-c/url_to_img.PNG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-2784303675187221966</id><published>2011-09-19T19:26:00.000-07:00</published><updated>2011-09-19T19:26:31.707-07:00</updated><title type='text'>How to hit offcampus in a good IT company</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;This is specially for the &lt;b&gt;MCA &lt;/b&gt;students who does not always get all the facilities of on &lt;b&gt;campus job &lt;/b&gt;but capable in all aspects . I am not a consultant but i have gone through the same thing . I also didn&#39;t get job in campus at my college , I worked as a &lt;b&gt;fresher &lt;/b&gt;in a small &lt;b&gt;software &lt;/b&gt;company for 1year ,&amp;nbsp; but Now i am in position where i wanted to to see me and i got work of my domain .&lt;br /&gt;
&lt;br /&gt;
&lt;i&gt;I am just going to give you some steps that i followed , and hope you will find this helpful:&lt;/i&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;color: blue;&quot;&gt;1) Make your domain knowledge as strong as possible (eg.&amp;nbsp; if you are in&lt;b&gt; IT software&lt;/b&gt; make your Database knowledge strong for whatever language you use ) anyways keep updating your knowledge&amp;nbsp;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;2) Make a resume that will highlight your&lt;b&gt; projects and work that you have done so far&lt;/b&gt; , add details .&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;3)Create your profile in all sorts of big job portals because may be they send irrelevant email all the time , but lots of consultants are there who looks for &lt;b&gt;fresher resume and give opportunity &lt;/b&gt;. To start your career with job given by a consultancy is not that bad as after gaining some experience you will be at a good position&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;4) Keep updating your profile once in week , that will make your resume available to the recruiter .&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;5)Don&#39;t sit at home idly , if you get any job in your domain do it for any salary but look for their contract first .&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;6)If you have some discrepancy in your academics then a 1yr experience in &lt;b&gt;IT industry &lt;/b&gt;will remove that , as the recruiter will try to find what you know in that domain , not what you scored at you 12th,Graduation or Masters&amp;nbsp;&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;7) To reach to the recruiter directly , try search with keyword in Google like that &lt;b&gt;&quot;Your domain&quot;+location(don&#39;t&amp;nbsp; give if you have no problems to travel anywhere in India)+&quot;Fresher&quot;+&quot;job&quot; (optional) &lt;/b&gt;Google will show you thousands of results and thousands of companies . Go to their sites go to career page there will be either a form to enter , upload your cv or their will be email-id of the &lt;b&gt;HR&lt;/b&gt; , mail your resume with a cover letter , a cover letter yo can use if you want .&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: blue;&quot;&gt;8) Subscribe your email-id to any kind of job sites&amp;nbsp;&lt;/div&gt;&lt;br /&gt;
Go for all opportunities , the recruiters will find you , Job will&amp;nbsp; be at your door . One year may be needed , but after that you will get placed surely&lt;br /&gt;
&lt;br /&gt;
Thank you friend ... if you find my advice helpful you can subscribe or enlist yourself in the followers list.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/2784303675187221966/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/how-to-hit-offcampus-in-good-it-company.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/2784303675187221966'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/2784303675187221966'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/how-to-hit-offcampus-in-good-it-company.html' title='How to hit offcampus in a good IT company'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-581444928897580402</id><published>2011-09-18T09:09:00.000-07:00</published><updated>2011-09-21T02:07:01.599-07:00</updated><title type='text'>Part 3 : Host WCF application in IIS</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;Step 1 :&amp;nbsp; We will add a website of&amp;nbsp; wcfService : right click on solution --&amp;gt; add niew item --&amp;gt; website --&amp;gt; select wcfservice , give name &lt;i&gt;&lt;b&gt;&quot;WCFServiceRegestration&quot;&lt;/b&gt;&lt;/i&gt; it will add a service file Service.svc it will add two more file in the appcode folder , but we will delete them as we dont need them&lt;br /&gt;
&lt;br /&gt;
Step 2 : We will add the reference the dll file of our wcf service in the website&lt;br /&gt;
&lt;br /&gt;
Step 3 : open the svc file and add the following code&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;lt;%@ ServiceHost Language=&quot;C#&quot; Debug=&quot;true&quot; Service=&quot;ServiceRegistration.Service1&quot;&amp;nbsp; %&amp;gt;&lt;/span&gt;&lt;br /&gt;
Service=&quot;&lt;span style=&quot;color: blue;&quot;&gt;ServiceRegistration.Service1&lt;/span&gt;&quot; follow the &lt;i&gt;&lt;b&gt;namespace.class&lt;/b&gt;&lt;/i&gt; hierarchy of your Service1.cs class in the wcf class , you can understand ... its too easy for you now&lt;br /&gt;
RightClick on the service file and click browse , so you will get the service WSDL :&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;http://localhost:1547/WCFServiceRegestration/Service.svc&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;Step 4:&amp;nbsp; Now lets edit our configuration file , right click on the the web.config file and click &lt;i&gt;&lt;b&gt;&quot;Edit WCF Configuration&quot;&lt;/b&gt;&lt;/i&gt;&lt;br /&gt;
the next part will be explained to the video , you will get it best from the following youtube video&lt;br /&gt;
&lt;a href=&quot;http://www.youtube.com/watch?v=mX8quq7MoeI&quot;&gt;Go to the URL&lt;/a&gt;&amp;nbsp;&amp;nbsp; but at the end of the section i will&amp;nbsp; show you how to host in IIS 5.1 version&lt;br /&gt;
&lt;br /&gt;
Step 5 : go to run section -- click inetmgr --&amp;gt; enter it will open IIS Manager&amp;nbsp; , go to websites --&amp;gt;right click Default Websites --&amp;gt; New --&amp;gt; Virtual Directory , it will open Virtula directory creation wizard --&amp;gt; click next  --&amp;gt; Give alias (any name ) (&quot;RegIIS&quot;) --&amp;gt; Click Next --&amp;gt; browse the website path and --&amp;gt;click next --&amp;gt; check browse , read and run as script click next and finish&lt;br /&gt;
&lt;br /&gt;
Step 6 : It will&amp;nbsp; add the web site in the list in the left website tree view click and it will show the files at the right panel right click on the service and click browse it will open the service in the browser and you will get the service URL as &lt;i&gt;&lt;b&gt;&quot;&lt;a href=&quot;http://localhost/RegIIS/Service.svc&quot;&gt;http://localhost/RegIIS/Service.svc&lt;/a&gt;&quot;&lt;/b&gt;&lt;/i&gt; so you can see service location is independent of the port number it is published in the IIS and you computer is acting as window server&lt;br /&gt;
&lt;br /&gt;
Step 7 : if there is any problem occurring with permission go for the following steps&lt;br /&gt;
right click on the site at the left panel RegIIS --&amp;gt; All Taks  --&amp;gt; Permissions Wizard  --&amp;gt; click next  --&amp;gt; check select new security settings from a template  --&amp;gt; click on public website  --&amp;gt; next  --&amp;gt; check on &quot;replace all directory ,,, ( recommended&amp;nbsp; )&quot;&amp;nbsp; click next and finish &lt;br /&gt;
&lt;br /&gt;
In the next tutorial i will invoke the Service from a new application &lt;br /&gt;
&lt;br /&gt;
Now you can invoke the wcf service methods without visual studio compiler ,,, first&amp;nbsp;search&amp;nbsp;for the phrase&lt;b&gt;&lt;i&gt; &quot;wcftestclient&quot;&lt;/i&gt;&lt;/b&gt; in windows search , get the path from title bar , copy it&lt;br /&gt;
go to command prompt change directory with cd - &quot;copied url &quot; -- hit enter , then type &lt;b&gt;&lt;i&gt;&quot;wcftestclient&amp;nbsp;&lt;a href=&quot;http://localhost/RegIIS/Service.svc&quot;&gt;http://localhost/RegIIS/Service.svc&lt;/a&gt;&amp;nbsp;&quot;&lt;/i&gt;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhsuGmqSLsn2enpw9Y3BSuMw2BdDr0OYAISZrqxup-koIS-1FaIyh3lDiPzDDAhGxh16MxMeakXaCmqtgR4hbzoy9Jt1FVTM70Pks4n7pwl_l40kq6OvS5YgRru44jsUSuLIvI0KiWsV5kQ/s1600/cats.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;152&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhsuGmqSLsn2enpw9Y3BSuMw2BdDr0OYAISZrqxup-koIS-1FaIyh3lDiPzDDAhGxh16MxMeakXaCmqtgR4hbzoy9Jt1FVTM70Pks4n7pwl_l40kq6OvS5YgRru44jsUSuLIvI0KiWsV5kQ/s400/cats.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;b&gt;&lt;i&gt; and hit enter , bingo the wcf test client will be opened and your service will be added&amp;nbsp;&lt;/i&gt;&lt;/b&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/581444928897580402/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/part-3-host-wcf-application-in-iis.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/581444928897580402'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/581444928897580402'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/part-3-host-wcf-application-in-iis.html' title='Part 3 : Host WCF application in IIS'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhsuGmqSLsn2enpw9Y3BSuMw2BdDr0OYAISZrqxup-koIS-1FaIyh3lDiPzDDAhGxh16MxMeakXaCmqtgR4hbzoy9Jt1FVTM70Pks4n7pwl_l40kq6OvS5YgRru44jsUSuLIvI0KiWsV5kQ/s72-c/cats.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-179573037255582341</id><published>2011-09-18T08:17:00.000-07:00</published><updated>2011-09-21T08:20:56.624-07:00</updated><title type='text'>PART 2 : Simple Login Control Using WCF Service and Linq</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;Now lets drag the table into the &lt;i&gt;&lt;b&gt;RegDB.dbml &lt;/b&gt;&lt;/i&gt;section it will create the DataClass &lt;i&gt;&lt;b&gt;MST_USER&lt;/b&gt;&lt;/i&gt; ,&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiFDiZtpTjOnxz8MGJft6-kc3ZLU0YD6jOgRRLnZHvMKstM5gTvexyXP3Z-ewnAQwTGiqNOYlP_MCHOuRSlaDXCZiAa4Y3PYPDVnf_B420rKd0dV9YKfgCzGxOEiAuWCeLdlicazyLZoLS5/s1600/1.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiFDiZtpTjOnxz8MGJft6-kc3ZLU0YD6jOgRRLnZHvMKstM5gTvexyXP3Z-ewnAQwTGiqNOYlP_MCHOuRSlaDXCZiAa4Y3PYPDVnf_B420rKd0dV9YKfgCzGxOEiAuWCeLdlicazyLZoLS5/s1600/1.jpg&quot; /&gt;&lt;/a&gt;&lt;/div&gt;Lets create a method for registration , where user will enter the four fields name,email,user id and password&amp;nbsp; in IService.cs file we will declare the data member and the method in the Service contract , copy paste the following code inside the namespace :&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;[ServiceContract ( Namespace=&quot;http://www.yoursite.com/&quot;),XmlSerializerFormat] &lt;b style=&quot;color: red;&quot;&gt;**&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; public interface IService1&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [OperationContract]&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; bool registration(string name, string email, string uid, string pwd);&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [OperationContract]&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; bool login(string uid, string pwd);&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Use a data contract as illustrated in the sample below to add composite types to service operations&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [DataContract]&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; public class UserInformation&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string _name;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string _email_id;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string _user_id;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; string _password;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; public UserInformation(string name, string email, string uid, string pwd)&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; _name = name;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; _email_id = email;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; _user_id = uid;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; _password = pwd;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [DataMember]&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; public string Name&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; get { return _name; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; set { _name = value; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [DataMember]&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; public string EmailId&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; get { return _email_id; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; set { _email_id = value; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [DataMember]&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; public string UserId&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; get { return _user_id; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; set { _user_id = value; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [DataMember]&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; public string Password&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; get { return _password; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; set { _password = value; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
we have declared two boolean methods &lt;i&gt;&lt;b&gt;registration &lt;/b&gt;&lt;/i&gt;for registering and &lt;i&gt;&lt;b&gt;login&lt;/b&gt;&lt;/i&gt; for login , return true if successful , any ways now we will call this methods in the &lt;i&gt;&lt;b&gt;Service.cs&lt;/b&gt;&lt;/i&gt; class , copy and paste the following code inside your &lt;i&gt;&lt;b&gt;Service.cs&lt;/b&gt;&lt;/i&gt; class namespace :&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp; public class Service1 : IService1&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; public bool registration(string name,string email,string uid,string pwd)&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; RegDBDataContext rdbc = new RegDBDataContext();&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MST_USER mu = new MST_USER { NAME = name, EMAIL_ID = email, USER_ID = uid, PASSWORD = pwd };&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; try&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; rdbc.MST_USERs.InsertOnSubmit(mu);&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; rdbc.SubmitChanges();&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return true;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; catch&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return false;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; public bool login(string uid, string pwd)&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; RegDBDataContext rdbc = new RegDBDataContext();&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var messages = from p in rdbc.MST_USERs&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; where p.USER_ID == uid &amp;amp;&amp;amp; p.PASSWORD == pwd&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; select p;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (messages.Count() &amp;gt; 0)&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return true;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; else&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return false;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;our wcf service is&amp;nbsp;&lt;/span&gt; &lt;/span&gt;now ready , lets invoke the methods and see whether its working correctly , so run the project after the successful build it will open the &lt;i&gt;&lt;b&gt;wcftestclient&lt;/b&gt;&lt;/i&gt;&amp;nbsp; environment and add the service&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgnbXbg_P1_8goXQFwy4WdXui_D4bZFcEIXaGTV9ND87zUYXGmcWPw0cbiDrC1ElGWOvQba9ONl0cyzpvEXCSeIostbeAaZKh12D14dLBmnQIp4Vv1tIP5z3D5iW7M9mk2CHE3D_wlKiCZf/s1600/2.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;251&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgnbXbg_P1_8goXQFwy4WdXui_D4bZFcEIXaGTV9ND87zUYXGmcWPw0cbiDrC1ElGWOvQba9ONl0cyzpvEXCSeIostbeAaZKh12D14dLBmnQIp4Vv1tIP5z3D5iW7M9mk2CHE3D_wlKiCZf/s400/2.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
we will click on any of the method it will let us to pass the required parameters then click invoke to invoke the methods , it will&amp;nbsp; return the result in the below response section , you can also view the xml format , give some relevant parameters and test your service&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiNhMcK37M0Qml57uDzxg32UyeAtc8h4SPYTbXnv6RQC3OxytCPRu0XlJP7KhIRcyESwCaIKXubJwWvZTHWaww7paGk_e-JrbqwBh7bBNhk2JR6xN-rvTg3P3qppkxIdhMKLVBOjyvD4jSH/s1600/3.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;247&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiNhMcK37M0Qml57uDzxg32UyeAtc8h4SPYTbXnv6RQC3OxytCPRu0XlJP7KhIRcyESwCaIKXubJwWvZTHWaww7paGk_e-JrbqwBh7bBNhk2JR6xN-rvTg3P3qppkxIdhMKLVBOjyvD4jSH/s400/3.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;so here our wcf service for registration and login is done , in the next tutorial we will host this wcf application in IIS and invoke the methods&lt;br /&gt;
&lt;br /&gt;
In the next tutorial we will&amp;nbsp; host this wcf application in IIS , Follow the link&lt;br /&gt;
&lt;a href=&quot;http://mynecessarycode.blogspot.com/2011/09/part-3-host-wcf-application-in-iis.html&quot;&gt;Part 3 : Host WCF in IIS&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;&lt;span style=&quot;color: red;&quot;&gt;**&lt;/span&gt;&lt;/b&gt; &lt;span style=&quot;color: blue;&quot;&gt;Read the following article &lt;/span&gt;&lt;br /&gt;
&lt;b style=&quot;color: blue;&quot;&gt;&lt;a href=&quot;http://mynecessarycode.blogspot.com/2011/09/problem-with-result-and-result.html&quot;&gt;Click here to read &lt;/a&gt;&lt;/b&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/179573037255582341/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/simple-login-control-using-wcf-service_18.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/179573037255582341'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/179573037255582341'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/simple-login-control-using-wcf-service_18.html' title='PART 2 : Simple Login Control Using WCF Service and Linq'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiFDiZtpTjOnxz8MGJft6-kc3ZLU0YD6jOgRRLnZHvMKstM5gTvexyXP3Z-ewnAQwTGiqNOYlP_MCHOuRSlaDXCZiAa4Y3PYPDVnf_B420rKd0dV9YKfgCzGxOEiAuWCeLdlicazyLZoLS5/s72-c/1.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5609619104114830730.post-6693376532738115361</id><published>2011-09-15T12:20:00.001-07:00</published><updated>2011-09-15T12:20:32.537-07:00</updated><title type='text'></title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;
&amp;nbsp;/// &amp;lt;summary&amp;gt;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; /// Loop through the work sheets of the excel file and set the column value&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; /// &amp;lt;/summary&amp;gt;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; /// &amp;lt;param name=&quot;ExcelFilePath&quot;&amp;gt;Excel File Path&amp;lt;/param&amp;gt;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; /// &amp;lt;param name=&quot;_XmlFilePath&quot;&amp;gt;Xml File Path&amp;lt;/param&amp;gt;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; public void LoopThroughSheet(string ExcelFilePath, string _XmlFilePath)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; try&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; _ExcelFilePath = ExcelFilePath;&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; XmlDocument doc = new XmlDocument();&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; doc.Load(_XmlFilePath);&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; XmlNodeList _x_node = doc.GetElementsByTagName(&quot;name&quot;);&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; _ReadOnlyOrNot = false;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; OpenExcel();&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; foreach (Worksheet ws in _ExcelWorkBook.Sheets)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (GetUsedRowCount(ws.Name) &amp;gt; 1)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; int _count_used_rows = GetUsedRowCount(ws.Name);&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; int _start_index;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; for (_start_index = 2; _start_index &amp;lt; _count_used_rows + 1; _start_index++)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (FetchCellData(_start_index, 1, ws.Name) != &quot;&quot;)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (i &amp;lt; _x_node.Count)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; SetCellData(_start_index, 2, ws.Name, _x_node.Item(i).InnerText);&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; i = i + 1;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; else&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; i = 0;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; SetCellData(_start_index, 2, ws.Name, _x_node.Item(i).InnerText);&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; i = i + 1;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; else&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; break;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; i = 0;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; else&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; break;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; SaveExcelAs(&quot;excel_test.xslx&quot;);&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; CloseExcel(false);&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; catch (Exception ex)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; MessageBox.Show(ex.Message);&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mynecessarycode.blogspot.com/feeds/6693376532738115361/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/loop-through-work-sheets-of-excel-file_15.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/6693376532738115361'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5609619104114830730/posts/default/6693376532738115361'/><link rel='alternate' type='text/html' href='http://mynecessarycode.blogspot.com/2011/09/loop-through-work-sheets-of-excel-file_15.html' title=''/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/18224466944310319559</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>