VS 2008 Class & DLL's - Create Scripts On Their Own And Allow Them To Interact With Main Sub

Dec 12, 2011

I want to start building my first large program. I want to create scripts on their own and allow them to interact with my main sub. I guess if I need a "plane" in my application, that could become it's own class? If I wanted to calculate "purchases", "money" I could create a DLL? I don't want to have to change things and have to recompile my entire application every time I want to change how something works for example.

View 5 Replies


ADVERTISEMENT

Create An Application Which Will Interact With SQL Server 2008?

Oct 10, 2011

I'm doing a project in VB.NET, in which the application will interact with SQL Server 2008 database. I know how to develop that application. But after created executable version of that application(.exe) i will install it in another machine. How will that application interact with database at that machine??

View 6 Replies

Class Has Been Create By Main Class Only?

Feb 27, 2011

I'm try to create a class has been create by main class only by protect sub New but how do I create it ?

Public MustInherit Class Rune
Protected MustOverride Function Create() As Rune
Public Shared Function Factory(Of T As Rune)() As T
'I can't use "T As {Rune, New}" because Sub New isn't Public
'Return (New T).Create
End Function
End Class

[Code]...

View 2 Replies

Create An Object From The Class - Use The Object To Interact With The SQL Db?

Apr 12, 2006

I am developing an IT Asset Tracking application using VB 2005 and SQL Server 2005 Express edition. Will I need to create classes to represent objects such as Computers, Printers, Scanners/Faxes, Contracts, Purchase Orders etc or are there any other approaches.For example, if I am correct, I will have a class called Computer and its properties will include Make,Model,CPU,Hard Disk,Memory etc. Is this the right approach.

Computers can be split up into Desktop PC's, Servers and Notebooks. Would I have to create separate classes for these as well or would they be ok under the Computer class.Once I create an object from the class, how can I use the object to interact with the SQL db.I am a beginner to VB.NET 2005 therefore I am slowly getting to grips with OOP.

View 13 Replies

Create A Sub Main Inside A Class Which Is Itself Part Of A Project

May 17, 2009

why, when i create a sub main inside a class which is itself part of a project, i need to create it as a shared sub like this.[code]

View 2 Replies

VS 2008 Can Call A Class From Main Form

Dec 14, 2011

As of the moment I have 24 buttons that are keys to a piano.24 of the button codes have a call method that calls the note to be played.24 of the private subs that are called have an .wav audio playback command within them. I was hoping I could move the .wav private subs into a separate class, and just call them from my main form, therefore cleaning up the lines of code I have at the moment. [code]That example only counts for one Button "The Key of C", and the audio file that is called with it. Multiply that by 24 and you get a big mess of repetitive junk.Can I move the audio subs into a class and call them from my main form?

View 16 Replies

VS 2008 - Make A Class Link Into Main Code

Feb 7, 2012

I'm just wondering, how do i make a class link into my main code, it is in the same project so no need to reference it

Ive set up the the class and typed

code:

But they aren't linking/ working.

View 11 Replies

VS 2008 - Sub Main In Module Versus Shared Class

Feb 17, 2010

In VB6 I always wrote my apps using Sub Main as the starting point. I see in .NET I'm able to wrap it in a shared class (see [URL] for example). However, the downside is that I can't declare any class-level variables, because of course the class is never instantiated. Being shared, it limits what the code can do. So, any benefit to use a shared class and shared sub main which I'm missing here.

Otherwise it seems using a module (as in VB6) provides a lot more flexibility. Of course, I should also ask if "Application Framework" is really the way to go for real-world apps, or if it's only there for beginners and real-world coders turn it off and use Sub Main instead? If so, how are the events "UnhandledException" and "NetworkAvailabilityChanged" done if App Framework is turned off?

View 28 Replies

VS 2008 Localization Globalization - Creat A 'sub New' In Main Class?

Mar 15, 2011

I'm busy creating a multi language application, so far so good. I've googled some examples, first problem I've encountered is setting it. Accourding the msdn documentation it had to be done BEFORE initializecomponent. I didn't know how, but found out you have to creat a 'sub new' in your main class.

[Code]....

View 1 Replies

Write A Class In Each And Make Its Variables Interact In One Application?

Jul 13, 2010

Write a class in each and make its variables interact in one application?

View 3 Replies

VS 2008 - How To Create Custom Shaped Form As Main Page Of App

Mar 16, 2010

I have need for a customised form as the main page of my app, what I'm looking for is to create an amoebic shaped form, something like this. I realize that my 'window' will by nature need to be rectangular and that i will need it to have no titlebar and transparent edges, also i will need to have 'regions' on this form that will allow the form to be closed and turned into a standard rectangular form. I have no idea where to begin with doing this but I hope and presume it is possible with vb.net. The image I have used is for illustrative purposes only, i don't plan to do exactly this (my app is a database not a media player for one thing) If having it is a breach of copyright in this context I will remove it.

View 39 Replies

VS 2008 Object Data - Create A Class And Create A Instance Of CarData?

Nov 28, 2010

I want to create a class is it where I can do...

[code]...

How do I do this? Do i create a class and create a instance of CarData? but how do I add Color and Year etc to it?

View 3 Replies

VS 2008 - Bunch Of Errors - Main Login Box And Then Fail To Show The Main Screen

Jul 28, 2009

My app works fine on the development machine and 3 other machines. However, some machines just show the main login box and then fail to show the main screen. There is no error message. I installed VS 2008 express on on of such machines and when i compile the project, the following errors appear:

Type 'Microsoft.Office.Interop.Access.Application' is not defined.
Type 'dao.DBEngine' is not defined.

[CODE]..........................

View 3 Replies

VS 2008 Interact With A Service?

Jul 13, 2011

I have never interacted with Varbiles outside of the projject but now in need of it.I am developing a Windows Service Application that is multi-threaded. There is going to be a set of Global Varibles in the application that contain basic status information such as how many threads are currently running, What clients are currently connected etc.

Now I would like to develop another application as a monitor. This one would be a Windows Forms App and its sole purpose is to display to the user this information so that is can be monitored.Is there an easy way of doing this? If not I don't think I will bother as the Monitor is not essential.

View 1 Replies

VS 2008 Making Forms Interact With Each Other Over The Internet?

Mar 12, 2010

This part of visual basic is new to me. How can i make multiple forms that each operate on different computers but can interact with each other and influence each other over the internet?

View 2 Replies

VS 2008 - Use An Icon In The System Tray To Let Interact With A Windows Service

Sep 24, 2009

I've seen loads of programs that use an icon in the system tray to let you interact with a windows service that is running on your machine but I am curious as to how this works. As I understand it, unless a service marks itself as 'interactive' then it has no way to communicate with the user's desktop and doing so is discouraged by MS (and even causes an alternate desktop to appear temporarily in Server 2008 in some cases). So I want to try and avoid doing this but I cant think how else I would do it, and even if I marked my service as interactive I'm not too sure how I could actually get it to show a notification icon in the system tray.

I assume I would have to use Windows APIs, unless just using the windows forms NotifyIcon class would work. I considered just having the system tray icon in a totally separate application that just communicates with the service via named pipes or TCP etc but I'm pretty sure this isnt how other programs do it because with most of them if you just kill the process that the service is running in then the icon disappears so it must actually be directly running from the service.

View 9 Replies

VS 2008 Develop A Web App That Can Interact With Websites And Carry Out Automatic Tasks?

Sep 7, 2009

I'm using Visual Studio 2008 on an XP machine and am trying to develop a web app that can interact with websites and carry out automatic tasks.One problem I have is trying to recreate the web requests for automatic interaction.

For example:I use a webBrowser control to allow me to surf a page manually. Then, once I am at a specific location, I'd like the automatic interaction to take over.Part of the website requires a log-in and exchanges cookie data.When I try to read the cookie info from the webbrowser control to build the subsequent automatic requests, the cookie content is incomplete.Upon further investigation, it appears that the site sets one of the cookies to "http only". This stops the value being visible to the webbrowser control.Is there another control or method I could use to retrieve this info?

View 1 Replies

VS 2008 UI Threading - Move/interact With Both Forms While The Loop Is Running ?

Oct 17, 2009

When it comes to threading. I've managed to adapt one of JMcIllhinney's backgroundworker codebank examples to somewhat suit my needs, but not completely. I have a main form, and a second form that appears while I'm running through a for loop. It informs the user what is currently happening. I set up a backgroundworker that allowed me to continue to use the main form during the for loop, but the other "status" form was completely frozen, and any labels or graphics were shown as white boxes. I am struggling to figure out how to be able to move/interact with both forms while the loop is running.

View 4 Replies

How To Call A Class From A Main Form

Mar 5, 2010

How would you call a class from a main form? In VB6 you would call a module by just simply calling the module name.

View 2 Replies

How To Refer To Main Window Class

Sep 6, 2011

I created a modal dialog as a WPF window that changes some settings in the main window application. How can I refer to a member of the main window?

View 2 Replies

Class Not Registered While Loading Main Form

Apr 1, 2009

We have a Dell laptop used to run an in-house VB.NET program. It got a virus. We had to wipe the hard drive and reinstall Windows from scratch. We use Windows XP Pro, which is what was installed on it before. But now our VB program won't run. After trying and despairing of getting remote debugging to work, I actually installed Visual Studio 2005 on the machine, just long enough to get information about what was making the program fail. And the failure was most peculiar. It isn't in our code. It's in the VB setup code that loads the main form. And it says, "Error loading form: class not registered."The gory details are given below. Now here's the strange thing. Not every VB.net program fails on this computer. And the program that fails, fails only on this computer; it has run successfully on several other Windows XP systems with .NET Framework 2.0 installed.[code]

View 3 Replies

Main Difference Between A Class And A Type And A ValueType

Dec 17, 2009

what's the main difference between a Class and a Type and a ValueType.and is a Delegate a Type? or an eventhandler/event (the actual event itself)is every object a type? or is it only true in VB

View 3 Replies

Set And Get A Value From A Class Property Within The Main Event Of A Module?

Jul 8, 2011

the project uses a submain as startup object which is located in a module, thy so the application will be started in tray. Within the main() event i need to deserialize a xml file and with it set the properties of a class and then set what the application will do.The problem is, after I deserialize it and put set the property values I try to get them in the same event(main) but when it gets the value it returns as nothing(if string) or 0(if integer) but in the debugging i saw it setting the values.Is there a way to do that, within the main() event of a module to set the properties of a class and then get them without being nothing/0 ?

View 6 Replies

Use The Update In The Main Class To Access The List?

Jan 15, 2012

i need to use the update in the main class to access the list in the footballadmin and then display each in a list box but i cant get it to work.

Imports Football
Public Class FootballAdmin
Private fTeam As List(Of FootballTeams)

[Code]......

View 10 Replies

Winforms - Serialize The Main Class In My VB Solution?

Apr 5, 2011

I'm trying to serialize the main class in my VB solution. I've added the Serializable attribute at the top of my class like so:

[code]...

I'm guessing this is because you can't serialize the form that is attached to the class or something, but I really don't know what I'm doing. Can I serialize all of the objects contained in my Form1 class somehow, without getting this error? I don't want to store any data about the form controls, I just need to save all the objects that I've defined at the top of the Form1 class.

View 1 Replies

Create A Class Template IN VB 2008?

May 3, 2009

create a Class Template for VB so that when I click Add -> Class, in the Add New Items window, that class will be displayed? And also the variables that are needed inside the class. I guess I need a tutorial.

View 3 Replies

VS 2008 - Any Way To Create Designer Class?

Sep 13, 2009

Is it possible to create a designer class in VB express? Because I can't import this namespace: System.Windows.Forms.ControlDesigner.

View 2 Replies

VS 2008 When To Create A New Class Instance

Jun 22, 2010

I understand if i was to create my own class i would need to declare a variable with the new keyword to create an object to access the encapsulated methods properties etc, unless they were declared shared.

dim myVar as myClass = new myClass

But in this next example is where i have become confused. i have added the mschart control to the form and used the hittest function with the following code.

Dim myVar as hittestresult
myvar = me.chart1.hittest(e.x,e.y)

Why wasn't it necessary to create a new instance of the class 1st. Does the hittest function return an object or a reference pointer to the object. To clarify what's the protocol for when & when not to create a new instance of the class in use.

View 7 Replies

Accessing Function In Alother Class From The Main Form?

Feb 12, 2011

I have a new solution with 5 projects inside. a data access layer, database, 2 class libraries, and the main form. These are all components that I had worked on to get to this point of combining into 1 solution. Now what I have run into is I can not the actual functions in the class libraries. I can get to the class level, but that is it. ere is a sample line of code I need to get working. Once I get this one line, the rest will be obvious: Temperature is on the main form. get for options is "Equals, GetHashCode, GetType", etc... Before this I had bult, compiled, and referenced these classes separately, and it worked fine. I know this is going to be an easy answer, I'm just not seeing it for some reason.

View 15 Replies

Declare Main Class On FrmMain - Working With Classes?

Jun 3, 2009

Currently I declare my main class on frmMain. as public MyClass as new clsMyClass Thus anywhere in the application I would address it as: frmMain.MyClass.Function(MyParam) This does not look as neat as I would like it. Where can I load this Class so that I can address it as: MyClass.Function(MyParam) from anywhere inside the application.

View 6 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved