<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
  <channel>
    <title>'Share Module to Any New Project' Thread RSS Feed</title>
    <link>http://www.programmersheaven.com/</link>
    <description>Contains the latest posts from the thread 'Share Module to Any New Project' posted on the 'VB.NET' forum at Programmer's Heaven.</description>
    <language>en</language>
    <copyright>Copyright 2012 Programmers Heaven</copyright>
    <pubDate>Thu, 09 Feb 2012 15:37:49 -0800</pubDate>
    <lastBuildDate>Thu, 09 Feb 2012 15:37:49 -0800</lastBuildDate>
    <generator>Argotic Syndication Framework 2007.3.0.1, http://www.codeplex.com/Argotic</generator>
    <docs>http://www.rssboard.org/rss-specification</docs>
    <ttl>360</ttl>
    <image>
      <url>http://www.programmersheaven.com/images/ph.gif</url>
      <title>Programmers Heaven</title>
      <link>http://www.programmersheaven.com/</link>
      <width>88</width>
      <height>31</height>
    </image>
    <item>
      <title>Share Module to Any New Project</title>
      <link>http://www.programmersheaven.com/mb/VBNET/408691/408691/share-module-to-any-new-project/</link>
      <description>Dear Forum&lt;br /&gt;
&lt;br /&gt;
I’m beginning at VB.Net and plan to Upgrade My VB 6 code to VB.Net 2005&lt;br /&gt;
&lt;br /&gt;
In VB 6, I can write a Bas module and Add the module to every project to share the function inside&lt;br /&gt;
But  i can’t find on VB.Net&lt;br /&gt;
&lt;br /&gt;
I trying to create a set of functions which will work for all forms in a visual studio .net visual basic 2005 project.  &lt;br /&gt;
I do not want to have to put the function code inside of every form.  It would be tedious and sloppy programming.&lt;br /&gt;
&lt;br /&gt;
Any Solution please ?&lt;br /&gt;
tq&lt;br /&gt;
&lt;br /&gt;</description>
      <guid isPermaLink="true">http://www.programmersheaven.com/mb/VBNET/408691/408691/share-module-to-any-new-project/</guid>
      <pubDate>Sun, 01 Nov 2009 22:29:30 -0800</pubDate>
      <category>VB.NET</category>
    </item>
    <item>
      <title>Re: Share Module to Any New Project</title>
      <link>http://www.programmersheaven.com/mb/VBNET/408691/408715/re-share-module-to-any-new-project/#408715</link>
      <description>Hi TQ! It's great to hear you are upgrading from nasty old VB6&lt;br /&gt;
&lt;br /&gt;
You can actually do just what you were talking about in VB .Net. &lt;br /&gt;
&lt;br /&gt;
Right click on your project name in the Solution Explorer. Go to&lt;br /&gt;
Add    &amp;gt;&lt;br /&gt;
New Item...&lt;br /&gt;
Module&lt;br /&gt;
&lt;br /&gt;
If you are in a Web Project, you might not have Module in the list of addable items. I usually add a ClassFile, delete it's contents and put this in:&lt;br /&gt;
&lt;pre class="sourcecode"&gt;
Public Module modCommon

End Module
&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Make sure you set the Module to be Public so your subroutines are visible by the rest of your application. Define the routines inside as public or private depending on what is calling them:&lt;br /&gt;
&lt;pre class="sourcecode"&gt;
Public Module modCommon
  Public Sub thisIsCalledFromOutside(Byval Var1 As String)
    callFromInside()
  End Sub

  Private Sub callFromInside()

  End Sub
End Module
&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Hope this helps!&lt;br /&gt;
&lt;br /&gt;</description>
      <guid isPermaLink="true">http://www.programmersheaven.com/mb/VBNET/408691/408715/re-share-module-to-any-new-project/#408715</guid>
      <pubDate>Mon, 02 Nov 2009 06:37:04 -0800</pubDate>
      <category>VB.NET</category>
    </item>
    <item>
      <title>Re: Share Module to Any New Project</title>
      <link>http://www.programmersheaven.com/mb/VBNET/408691/408743/re-share-module-to-any-new-project/#408743</link>
      <description>tq seancampbell,&lt;br /&gt;
&lt;br /&gt;
i'm develop windows application at now and not in web project,&lt;br /&gt;
Sir, i follow already, but still not clear&lt;br /&gt;
&lt;br /&gt;
explain in detail : &lt;br /&gt;
&lt;br /&gt;
1. New Project-1, have a module call "Module A"&lt;br /&gt;
2. then i make another NEW project-2, and i need the function of the "Module A"&lt;br /&gt;
&lt;br /&gt;
what i'm do in Project-2, I add the existing "Module A", but the "Module A" now become 2 file&lt;br /&gt;
(in VB.6 only one, and never make a copy)&lt;br /&gt;
&lt;br /&gt;
when i update the function of "Module A" in project-2, the same "Module A" in project-1 were not updated&lt;br /&gt;
&lt;br /&gt;
may assist again Sir ?&lt;br /&gt;
tq&lt;br /&gt;</description>
      <guid isPermaLink="true">http://www.programmersheaven.com/mb/VBNET/408691/408743/re-share-module-to-any-new-project/#408743</guid>
      <pubDate>Tue, 03 Nov 2009 01:00:56 -0800</pubDate>
      <category>VB.NET</category>
    </item>
    <item>
      <title>Re: Share Module to Any New Project</title>
      <link>http://www.programmersheaven.com/mb/VBNET/408691/408769/re-share-module-to-any-new-project/#408769</link>
      <description>You must link to the same file from both projects.&lt;br /&gt;
&lt;br /&gt;
Try this:&lt;br /&gt;
&lt;br /&gt;
1. Start a new project (or use one of your existing ones)&lt;br /&gt;
2. Create a new Module and call it LinkText.vb&lt;br /&gt;
3. Add a Function to it, and save it.&lt;br /&gt;
&lt;br /&gt;
4. Start a new project (or use a different one that already exists)&lt;br /&gt;
5. Right click the solution in the Solution Explorer&lt;br /&gt;
6. Select Add &amp;gt; Existing Item...&lt;br /&gt;
7. Find and highlight the file you want to LINK to&lt;br /&gt;
8. Click the Down-Arrow-Carrot that is on the right of the ADD button.&lt;br /&gt;
9. Select "Add as Link"&lt;br /&gt;
&lt;br /&gt;
You can see that the icon for the file you just added has a shortcut indicator in it. That means that this file is added as a link. Changes made in the file here affect the file in your other project.&lt;br /&gt;
&lt;br /&gt;
I hope this helps.&lt;br /&gt;
&lt;br /&gt;
&lt;a href="http://msdn.microsoft.com/en-us/library/9f4t9t92.aspx"&gt;http://msdn.microsoft.com/en-us/library/9f4t9t92.aspx&lt;/a&gt; (scroll down some, add existing item as a link)&lt;br /&gt;
-Sean Campbell</description>
      <guid isPermaLink="true">http://www.programmersheaven.com/mb/VBNET/408691/408769/re-share-module-to-any-new-project/#408769</guid>
      <pubDate>Tue, 03 Nov 2009 06:10:09 -0800</pubDate>
      <category>VB.NET</category>
    </item>
    <item>
      <title>Re: Share Module to Any New Project</title>
      <link>http://www.programmersheaven.com/mb/VBNET/408691/408815/re-share-module-to-any-new-project/#408815</link>
      <description>Dear Sir&lt;br /&gt;
&lt;br /&gt;
Wow... thank you Sir&lt;br /&gt;
I solve the problem&lt;br /&gt;
&lt;br /&gt;
don't know so simple, i wasting my time a week, just to browse and find the solution&lt;br /&gt;
&lt;br /&gt;
tq so much Master Sean Campbell &lt;br /&gt;</description>
      <guid isPermaLink="true">http://www.programmersheaven.com/mb/VBNET/408691/408815/re-share-module-to-any-new-project/#408815</guid>
      <pubDate>Wed, 04 Nov 2009 03:49:36 -0800</pubDate>
      <category>VB.NET</category>
    </item>
  </channel>
</rss>
