IDE :: Vb 2008 Class Library Settings Disappear?

Mar 12, 2011

Solution has 3 Class Libraries and 1 Windows Form application projects. For no apparent reason, one of the Class Libraries keeps loosing its Settings. These are primarily configuration strings. When I try to add them back in the IDE, they disappear again without explanation.

View 5 Replies


ADVERTISEMENT

Change Class Library's Settings From An Another Program?

Apr 8, 2009

I want to change my class library's settings from an another program. For this, I've made a Public property in my class library. It worked right. But this is not my question. I wonder this is a right method? Can I access a class library's settings (My Namespace) from other project directly?

[Code]...

View 4 Replies

Class Library Config Files And My.Settings

May 19, 2010

Say I have a Class Library project with its own .dll.config, and a forms application. I want to confirm that it is impossible to reference the .dll.config file from the .exe.config file and still use My.Settings.

For example: I have SomeClassLibrary project, with SomeSetting that I can access through My.Settings.SomeSetting. I also have SomeFormsApp project. This is what I want my SomeFormsApp.exe.config to look like:

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

[Code].....

From my readings, this seems impossible. I either need to copy the content of SomeClassLibrary.dll.config into SomeFormsApp.exe.config, which is tedious and error prone when copying from multiple class libraries, or I need to use ConfigurationManager, which bypasses My.Settings and its typed, Intellisensed goodness.

View 9 Replies

Class Library Getting Settings From Own App.config NOT The Application's?

Jun 2, 2009

I'm having trouble with my application settings and I'm wondering if anyone else has seen this.

I have a Librabry with a connection string. In the project for the library it has its own app.config:

<configSections>
<sectionGroup name="applicationSettings" type="System.Configuration.ApplicationSettingsGroup, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" >
<section name="OBInfrastructure.Settings" type="System.Configuration.ClientSettingsSection, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
</sectionGroup>

[Code]...

View 1 Replies

VS 2005 Access Settings In A Class Library?

Jan 1, 2010

I have created a Class Library project to create a VB.net 2005 DLL file. I am trying to access My.Settings in this class library project and not able to. How would I do this?

View 15 Replies

C# - Saving Class Library User Settings In Winforms .Net 3.5 SP1?

Jul 8, 2010

A while back, I wrote my own settings provider because I was having problems persisting settings in a class library. (Note - I had no problems persisting settings from an application).Today, I just did a test of persisting class library settings and it worked, without my custom provider.The test is:

(1) Create a class library

(2) Add a setting - 'Name'

(3) Add a class with a public shared property 'Name' that reads and writes to the setting 'Name'.

(4) Create an application that references the class library, and use the shared property to read and write the 'Name' setting.

I'm sure that before the 'Name' setting would persist while the application was open but after I closed it and re-opened it, the setting would revert to the default.This is not happening now and I'd like to be sure that I was being an idiot before and not an idiot now.

ETA: I've noticed that the first time I create a test app, change the setting, close, and reopen, the setting is not persisted. Subsequently it is. May be I gave up after one try before. Any ideas why it's not persisted the first time?

ETA2: As an example, I have a class library called 'MyLibrary' and a test application called 'MyApp'. I do the steps 1-4 above, and below are the contents of the user.config file found at C:Documents and SettingsUser NameLocal SettingsApplication DataMyAppMyApp.vshost.exe_Url_vi5gjcooahbdm2ma3dcay0mkexu2suul1.0.0.0. Note: I did not touch the settings in MyApp;-

<configuration>
<configSections>
<sectionGroup name="userSettings" type="System.Configuration.UserSettingsGroup, System, Version=2.0.0.0, Culture=neutral >
<section name="MyLibrary.My.MySettings" type="System.Configuration.ClientSettingsSection, System, Version=2.0.0.0, Culture=neutral, allowExeDefinition="MachineToLocalUser" requirePermission="false" />

[code].....

View 1 Replies

Asp.net - Getting Configuration Settings From Web.config/app.config Using Class Library

Mar 26, 2009

I have a class library (Named ADI), that needs some configuration settings from the project using it (like connectionstring, filesystem locations etc).

I want to define these settings in my Windows Forms/Web Projects App.Config or Web.Config, like other settings.

Here is part of my app.config for my windows forms application:

<applicationSettings>
<PhotoImportRobot.My.MySettings>
<setting name="ADIImageRoot" serializeAs="String">

[Code]....

View 3 Replies

VS 2008 Using A Class Library

Jul 24, 2009

I have a legal copy of a dll that I've used for years in VB6. Now I want to use it in VB.net. However, when I try to reference it, VB.net won't let me, displays an error. Tried to register the dll, got a no entry point error.

[Code]....

View 6 Replies

VS 2008 How To Make Class Library

Apr 7, 2010

Public Function Add(ByVal Number1 As Integer, ByVal Number2 As Integer)
Try
Return Number1 + Number2

[code]....

View 2 Replies

VB2010 Class Library: Create A Static Library Instead Of DLL?

Jun 21, 2011

I have a Visual Basic Class Library project. It generates a DLL. Is there a method to generate a static .LIB to which I can do a static link?Alternatively, can I do a static link against a DLL?

View 6 Replies

VS 2008 - Adding Class Library To My Project

Aug 8, 2009

I have a class library called Encrypt.dll that I added to my project (that class encrypts strings..). I have a problem that when I drag the app out of the Release folder, it crashes, giving me this error:Could not load file or assembly 'Encryption_Class, Version=1.0.0.0...' or one of its dependencies. The system cannot find the file specified.What am I doing wrong?I added it from the Reference tab->Add->Encrypt.dll

View 4 Replies

VS 2008 .Net Class Library DLL And Component Services?

Nov 23, 2009

I have a DLL file i have made in VS2008...builds with no errors...but when i go to add it to my servers component services i get an error...i have attached a screen shot of where i am getting the error and what the error is...i even tried to make a simple single class dll with the following:

[Code]...

View 6 Replies

VS 2008 : Install A Class Library On A Workstation

Apr 17, 2009

Is there anyway to install a class library on a workstation so any application can call it without it being bundled with that app?

View 6 Replies

VS 2008 Create A Class Library In C# And Then Use That Dll In A .net Project?

Dec 30, 2009

I know you can create a class library in C#.NET and then use that dll in a vb.net project and everything is just peachy. But can you use C++.NET and VB.NET/C#.NET in that manner?

View 2 Replies

VS 2008 Custom Dialog In A Class Library?

Mar 3, 2010

It's been a while since I last posted something, but this attracted my attention. Since many of my programs share the same type of code, I decided to dump it all in a class library for other programs to use.

Now I have a problem, Windows Forms in a class library can't be displayed. There is no "Show(Dialog)" command, only some for event handling. All properties are gone as well. The only way I managed to display a form is by making it as a new variable: 'Dim f as windows.forms.form

But this won't work because of the enormous amount of handlers added to the original.

How can I show my (TextureBrowse in my case) Dialog so other programs can use it?

View 9 Replies

[2008] Class Or Library That Have All The World Countries And Then Add Them To Combo Box?

Mar 13, 2009

i saw in many website that there's a combobox that display all the world countries to choose one of the country as your country.so i want to do this in program.is there any class or library that have all the world countries and then i add them to combo box?or do i need to enter them manually?

View 10 Replies

Deploy A 2008 Express Class Library Project (addin Dll)?

Mar 16, 2009

I'm not sure if this is the right forum or not but...I've written my first VB.NET 2008 Express Class Library project (addin dll) and now I need to deploy it. I see Windows Form Applications have a Publsh tab (ClickOnce) in the project properties window but my class library project does not. How do I deploy a VB.NET 2008 Express Class Library project?

View 8 Replies

VS 2008 Rising Events From Class Library Called From Module

Jan 26, 2010

I've an app that starts to work from a module wich should load a form an do other things with a class library who raise an event an the form shoud cath it. The problem is that applicarion.run(frmMain) displays the form in the same thread the the code stops work while the form is open. And I need that the app works in this way because the user need to send files to the app using args and this avoid that the app init another instance of it (in other code) and update the form with the info when the event is raised.

[Code]....

View 5 Replies

VS 2008 Class Library - Declare New Instance Of MainClass() Before Using Subs/Functions In Class2 Or Class3?

Feb 3, 2011

Namespace MyClassLib
Public Class MainClass
Public Sub New()

[CODE]...

Is it possible to make it so that the user using the Class Library has to declare a new Instance of MainClass() before using Subs/Functions in Class2 or Class3?

View 2 Replies

Difference Between Standard My.settings And Adding A New Class That Is Of Settings?

Mar 3, 2009

my old vb6 program used to store to ini files now with .net I rekon I need to do something new.. was thinking XML but then in searching around I stumbled apon this my.settings stuff.. so I followed the instructions but something strange is going one..

1. whats the difference between the standard my.settings and adding a new class that is of settings ? anything ?

2. I made 10 new settings in the setting manager but when I try to change then it gives me the old squiggle line saying no go.

View 15 Replies

Adding A Windows Service Class To A Class Library

Feb 14, 2012

I have a class library in VB.NET that does a NET-envelope for an USB device driver.There is only one function of that driver that I could not envelope in a traditional class, but I had to put it in a Windows Service as described here:Sharing a class property (field) between applications.The Windows Service works fine, but I have now two projects for my NET-envelope: the one with the class library, the second with the windows service and I do not like the idea to maintain two distinct projects for the same driver.Is it a good practice (or even if possible) to add a windows service class to a normal class library (without creating its own project as described in the vb tutorial)?I know, in any case I should create a separate setup only for the windows service, but in this way I could have together all the classes that envelope my usb device driver in only one project.

View 1 Replies

Creating An Instance Of A Class From A Class Library?

May 18, 2010

I've createda vb.net class library where I've defined a number of small classes... nothing complicated, just working with strings, sending emails, etc.In another project, I reference the class library and I'm seemingly able to create an instance ofone of tclasses - intellisense shows me all of the plic properties, methods, etc... all looks perfect. No compile errors at all, nothing b gumdropsand lollipops.When I run the app I'm working on that references the class library, it fails at the point where I'm creating an instance of the class and gives me a vague exception, "System.TypeLoadException".

View 2 Replies

Private And Public Class At Class Library

Mar 12, 2011

I'm posting this there is a relationship with my previous post [URL]

I have two projects, namely:

1. Project1 (Windows Application)

2. Project2 (Class Library)

in Project2 there are several classes:

* frmLogin.vb
* frmCustomer.vb
* clsGlobals.vb

in my case, I want to frmLogin.vb and frmCustomer.vb not called in Project1 and I can only call is clsGlobals.vb

View 8 Replies

VS 2008 : Load Forms From A Class Library Project (.dll) Into New "menu Application"?

Apr 8, 2011

I have a class library project (.dll) which contains a couple of forms.I now have a new project that would be the Client.

1) How do I load the forms from the dll into this project at runtime?

2) How do I set the client to be the MDiParent of the forms that will be opened from the dll?

View 1 Replies

Made A Class Using New->Class Library

Nov 17, 2009

I have made a class using New->Class Library. I have 2 constructors, 1 function (that computes length of circle), one subroutine that computes area of circle, and main subroutine.

Public Class Class1
Class Circle
Dim rad As Double

[CODE]...

My problem is when I try to run the program: No errors of syntax.

What I must do? I need to right click in solution explorer add new item->add->class and copy here this code?

After I write the code I chose from the vb menu: Build->Build Solution_name

Before writing the code I choose File->New->and selected class library then save all to save as a project.

Or class library is only a dll file that runs with a windows forms application. (that is added after i write the code for write library).

View 7 Replies

VB 2008 Express Forms Disappear

Jun 30, 2009

I just installed VB 2008 Express and started a project.When I saved it, closed it, and re-opened it, my form was GONE! When I try to click on Form1.vb, it's blank.The project still runs properly.

View 4 Replies

VS 2008 Code Makes All Disappear

Jan 21, 2010

I'm have coded some code so that when Ball1 hits objects extra1 or extra2 or extra3 or extra4 or extra5 then that extra what ever value was hit would disappear. But for some reason when ball1 hits one of them they all seem to go.[code]

View 12 Replies

.dll In Class Library?

Dec 29, 2009

there's a lot of dlls i've got one in the Release folder and one in the Debug folder under bin, there seem to be one in the obj folder as well.they all seem to work fine, but which should be the correct one?

View 4 Replies

Class Library Or Not?

Oct 18, 2010

I have two projects; A and B, where B needs to use some classes that are in project A. Hence, I added B to A's solution, and in B I added a reference to project A.

Is that sensible? Or should I rather put those classes in a class library?

I see that if I further want to open form/program B from a menu option in project A, then A needs a reference to B. Which would not be possible if B already had a reference to A. However if I use the class library for the common classes, then it's ok as B doesn't need the A reference.

Does this sound logical? It would be nice to know what are typical reasons for putting projects in the same solution, and if it's advised to use libraries aggressively to refactor common code between two projects, even if it's just a couple of classes.. Yet I've never made my own library, so a bit unsure on when to use it.

View 5 Replies

VB 2008 - Image Keeps Moving Out The Borders And Disappear

Apr 23, 2011

I have created a new project in visual basic and imported a photo in now i want to make the image move inside and I did that the problem is that the image keeps moving out the borders and disappear I want to make it stop how I should do that?

[Code]...

View 2 Replies







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