VS 2008 : Set My.settings.test To 0 Value?
Aug 30, 2010how to set My.settings.test to 00.00 value every 24 hours?
View 25 Replieshow to set My.settings.test to 00.00 value every 24 hours?
View 25 RepliesI have this code, how can I test the URL which is stored in My.Settings.MyLink to make sure the link is valid before it tries to get the elements of my xml file.
Dim myXMLTextReader As New Xml.XmlTextReader(My.Settings.MyLink)
myXMLTextReader.ReadStartElement("ATypes")
Do While myXMLTextReader.Read()
[Code]....
I have a constructor that looks like this:
Public Sub New()
MyBase.New()
ws.Url = My.Settings.WebServiceURL
End Sub
(ws is private)
Is there any point in unit testing this?
The class did not previously have this constructor.
I am rewritting my application to conform to ms standards. We used to save all settings to registry for user settings, servername, size and locations.so we are now saving them into My.Settings app.config the only problem is that each time there is an update clickonce will isntall the newupdate but now all settings are loist and user has to save everything all over again..
I am trying to follow the book here but it seems i keep getting stuck somewhere. registry has worked fine for years but i understand we must move on, but if stuff like this happens then i just wasted a long time converting all code to conform for it to not work..
I have created a settings-file for my plug-in-based app. When the mainApp writes the settings to the file, the pluginApp should read the settings from the settings-file (when opening or at runtime even better), but somehow it reads the settings from the app.config-file. This means that the pluginApp never will read the settings according the values of the file.
View 4 RepliesI saw that you can also use a "Settings File" (Add new Item)to add your settings instead of the application settings. But I can't seem to write any values to the file. Someone with experience with the "Settings1.settings"?
View 2 RepliesI don't understand the error, Argument not specified for parameter 'test' of 'Public Shared Function TestThis(test As String)'.
Partial Public Class Form1
Shared Sub ReceiveCallback(ByVal ar As IAsyncResult)
Form1.Invoke(TestThis, New Object(){"test"}) 'error
[code].....
I set up some application settings for checkboxes on an app and then decided to remove them. When I set the Application Settings to (none) in the designer and restarted the app, the checkbox constantly checks and unchecks itself. I completely remade the app and removed the file that is used to store my.settings in the Local folder of the user's appdata profile. I also made sure to uncheck the "save my.settings" on shutdown.
View 6 Repliesexample 1:First....hen...(Because 4 is less than 70)Example 2:irst...Then...(Because 70 has a number which is 4 it will no longer be tested so we will test the second number which is 5)
View 8 RepliesI am trying to test if my synchronization mechanism is set well and so for debug purposes, inserting a deliberate deadlock as under
mtx.waitone(-1)
mtx.waitone(-1)
but when i step through the code in the debugger, it runs fine without getting stuck here. I am sure there is no other thread doing a release on the mutex mtx
how can i test if datable exists?
View 1 Repliesif I could make a tcp server and client so he can restart a game server from a LAN connection. The game server is a test server for online playing games it allows users to test there created maps but after so many errors the program is told to close out the running server cause of errors. The problems are fixed just by restarting the server. I have the client working as far as i know (cant do a full test without a server). During the creation of the TCP client built within the server (to receive commands and send reply) ive used
[Code]...
I am accessing an sqlite database file from my VB.NET application.Currently, I use Try... Catch when opening the connection to the database, however if the database is locked by another application, it will take 5-10 seconds to throw the exception which says that the database is locked.
So I want to know if there is a way to test if the database is locked before I try to open the connection... because the long 5-10 second pause is annoying.
I fill a datatable using the dataadapter. and i set the adapter.missingschemaaction = missingschemaaction.AddwithKey. i set the insertcommand,updatecommand and deletecommand for the adapter as well.however, when i click on the datagridview to add new rows a new temporary primary key is not generated in my datatable.I've done this with access and sql server 2005 with no problems. im using MySQL.Net connector 6.1.2
View 4 RepliesI need test data for a IP Subnet calculator I have developed. I have tested some obvious scenarios, and all seems good, but the person developing can often be the wrong person to test.
The calculator can do one of two things:
1 - given an existing network and CIDR(mask), and a new CIDR it will create a number of networks with the appropriate number of hosts.
2 - given an existing network and CIDR(mask), and a list of c,h, (c = count, h=number of hosts) it will create the networks.
I need to make a condition such that my program waits until the webpage is completely loaded before executing my provided commands.
View 10 Replies[code]...
and from VB6 project I reference to Test.dll but an error messege was appear A reference to Test.dll file could not be added (If I create VB NET project and reference to file Test.dll it OK )
I am trying to create a unit test similar to how I would have done one in C# but am struggling with the lambdas in vb. Bascially I am trying to mock a class and then create a stub and return. In C# I would have done something like;
MockedPersonRepository
.Stub(x => x.Find(id))
.Return(person)
[code].....
I recently upgraded to Vista Business from XP Home. I found that my Visual Basic 2008 graphics applications is running much much slower in Vista than it was in XP. I took a small piece of my application and created a test program. I've set my computer up for dual boot so I now have XP Home and Vista Business on it. I've run my test program from both OSs and the results are tremendously different.
I have a custom built computer that has a Microstar Int. KT6 - V mother board. It has an AMD Athlon XP 3200 + 2.2 GHz with 2 GB RAM. It's a 32 bit processor. I do have the 32 bit version of Vista installed. I have only PCI slots and one AGP slot on my mainboard. I'm using a NVIDIA GeForce2 Graphics card that I bought back in 2005 with 32 MB RAM. My Vista Experience Index subscores are as follows:[code...]
I'm going to attach the program I created and someone can let me know if they were able to install it and run it from the attachment. If you run it let me know your results if you run it from Vista and let me know your computer set up. What's all the goods on your computer. What kind of graphics card do you have. Is it PCIexpress, PCI or AGP.
I have to write a program for a user to take a 20 question test (A, B, C, D). The users answers will be stored in an array and compared with a 2nd array that has the correct answers. Its then supposed to go to a 2nd form when you click show score, grade it, and display whether each answer was right or wrong. I'm missing something easy probably.
CODE:
Probably a dumb question, but can you write a unit test project in one language to test against another project in a different language?I'd like to translate one of our VB assemblies into C#, but want to build unit tests to verify the results. I've tried to set a unit test project up to do this, but I can't seem to access the VB code within a unit test... I can't figure out if I'm just missing/doing something stupid, or it really isn't allowed.
View 2 RepliesI have read about Network.Downloadfile and I think I understand it! I want to know if there is an easy way to test a files date modified before downloading it. I have a lot of files in the folder. I really want to "sync" the folder. I don't want to copy every file every time I want to only download the file if I don't have the file in the destination location or if I have an Old copy.
View 4 RepliesThe company has been using Visual Studio 2008 and .NET Framework 2.0 for approximately 2 years. During that time we released several versions (4.x.x) of our program to the public and were able to preserve the user's settings using My.Settings.Upgrade.During the past development cycle we upgraded the program to Visual Studio 2010 and .NET Framework 4.0 and changed the version to 5.x.x. Now, when a user upgrades from 4.x.x to 5.x.x they lose all of their settings.However, in all upgrades after that point (ie 5.0 to 5.1) all the user's settings are once again preserved.I checked C:Documents and Settings<USER_NAME>Local SettingsApplication DataCompanyName and it contains two directories:
ApplicationName_Url_aaa ApplicationName_Url_bbb
where aaa and bbb are 32 character strings. All of the user.config files for the 4.x.x releases can be found in the ApplicationName_ Url_aaa directory. All of the user.config files for the 5.x.x releases can be found in the ApplicationName_Url_bbb directory.Based on this information it seems like something changed when we converted our program to VS2010 and Framework4 that is now causing a different 32 character string to be generated. However, we have been unable to track it down.
I have the following structure:OLD: frmMain (WinForm)uscStat (UserControl with Grid) In frmMain I'm able to make some settings and load the result of the settings via LinQ into the Grid of the uscStat.
[Code]...
I just wondered if you can or can't save arrays using the settings system object. There seems to be no way of entering it at designtime. It seems implied you cannot create new user settings.subobjects at runtime. I'm looking to find the easiest way to save a populated array of PictureBox's. If the only way is a self/custom made/managed .ini file then I need to know so i can start on that but I was hoping to use some of all this phaff in the new frameworks usefully.
View 3 RepliesIs there a way to maintain application modified Settings in the settings files after a program update? i.e. I have 10 or so values in the settings file and the users can modify them... when I send a program update they revert back to what I initially programmed them to be.
View 3 Repliesi have created a user setting named 'setmeup' as string, scope = user, value = "magical meow meow!".in my code i access it and assign it a new value like this...my.settings.setmeup = "howdy cowboy!"my.settings.save()application.restart()when the application restarts, i expect the my.settings.setmeup = "howdy cowboy!" but when i check its contents its still "magical meow meow!".but when i use application.exit() instead of application.restart() and manually restart the program, my.settings.setmeup = "howdy cowboy!" which is correct.what must i do? i want to use application.restart() because i don't want the users to double-click the icon again to start the program. i want the program to restart automatically.
View 2 Replies1. I can't find the file which reflects changes to user settings. This might be because I just can't find it (I can see a bunch of user.config files but they are all empty - weird!), or...
2. I'm not actually saving them when I think I am.
Regarding 2. - do I need to invoke
Is this all I need? And if so, why are my user.configs empty?
I'm working with an Treeview and i'm new at it and i have 2 questions.
1. How can i save the treeview items, to settings (my.settings.history)
2. How can i save the treeview items as an TXT or XML file or another exception.
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.