Hello
I have the following program: i made a console application in a windows form, i've put all the code in the MainProgram.cpp (not the Form1.h) and now i would like to do the following (managed to make the application show both the form and the console at the same time)
When i click a button from the form, it should activate a switch - case portion from the MainProgram.cpp  , which acts like a menu.
Since...
					
					
						User Profile
				
					Collapse
				
			
		
	- 
	
	
	
	
Windows Forms button click activates console command
 - 
	
	
	
	
I need to upload it on the net first, and i don't know exactly what to upload, the WHOLE source? Neither do i know how to upload it, as in, most uploading sites give you the site where if clicked you automatically start the downloading process. - 
	
	
	
	
:O
I must learn how! I've read a lot about it but every "guide" was really complicated, they said first i must make an xml with the version, then compare the 2 versions (the new one and the old one) and if bla then bla, if not then....ugh, i kinda stopped there since there were a few pages. Do you know any cleaner solutions?Leave a comment:
 - 
	
	
	
	
Hmmm but how does ClickOnce update the application? Does it uninstall the old one and install the new one? Or can it just replace some files without uninstalling anything?Leave a comment:
 - 
	
	
	
	
Well my application when i debug it has this configuration path:
C:\Users\[my user name]\AppData\Local\ Microsoft\MainF rame.vshost.exe _StrongName_qkl lcxzawdnpexuhgv do4141qzecd3sw\ 1.0.0.0\user.co nfig
When i publish and install it its here:
C:\Users\[my user name]\AppData\Local\ Apps\2.0\Data\X ZZMY5EO.68H\ZGP B4VPK.09L\main. .tion_2f092bac0 42a4cc2_0001.00 00_adb1741db8a6 d54b\Data\1.0.0 .0\user.config
(the last part changes...Leave a comment:
 - 
	
	
	
	
A last question, i've heard people saying that saving data in settings isn't so efficient as saving it in an XML. Is that true? Since saving in the settings is much easier than the XML stuff.Leave a comment:
 - 
	
	
	
	
 - 
	
	
	
	
I'm sorry but it pops 3 errors:
1. it wont allow me to add ".dll" at the system.configur ation
2. it says that ConfigurationMa nager does not exist in the current context
3. it says that ConfigurationUs erLevel does not exist in the current context
I've removed the .dll and that fixed one problem.Leave a comment:
 - 
	
	
	
	
I've found the path with
Great thinking btw :D , sadly the config file there is with the default values. Will make the XML file and check if it turns up in there. Thank youCode:MessageBox.Show(Application.ExecutablePath);
Leave a comment:
 - 
	
	
	
	
Thanks mate, i couldn't find it though, the folders were either empty or full of clicksomething . manifest or so, no config whatsoever. I decided i should stop using settings to save my stuff, and instead save them to an .xml file with xmlreader since as ive heard, it more efficient (resource-wise)
But thank you very muchLeave a comment:
 - 
	
	
	
	
Yes, indeed i am :)
Ive heard people using others but its kinda complicated for me to find another program to compile it, i would though if it would show me the settings file!Leave a comment:
 - 
	
	
	
	
I've looked over that several times, I got a [appname].exe.config.dep loy (after i install it on my computer) and one [appname].exe.deploy
The problem is that the .exe.deploy one is unreadable and the first one contains all the settings with the 0 value, even though in my application they increase and save themselves reloading the same values when i reopen the application.Leave a comment:
 - 
	
	
	
	
Yes that did cross my mind (about the txt file) but i was hoping i can find them somewhere in an xml file (since the application knows the saved settings after closing and reopening it)Leave a comment:
 - 
	
	
	
	
Where do settings get saved once the application is running?
Hello
I would like to find out where (in what file) do settings get saved when my application runs (made with windows forms - after i publish my application, not when i debug it). All my settings are saved with the Scope being "User" and the default value being 0.
For example i got this code
...Code:int x; x = Properties.Settings.Default.xSetting; private void buttonAdd_Click(object sender, EventArgs e)
 - 
	
	
	
	
Just found a very nice template, thought i might share it
...Code:public partial class Form1 : Form { public Form1() { InitializeComponent(); //Load saved settings this.Location = Properties.Settings.Default.Form1Location; this.Size = Properties.Settings.Default.Form1Size; //Allow changes to be implemented this.StartPosition = FormStartPosition.Manual; //capture changesLeave a comment:
 - 
	
	
	
	
I've been looking at several tutorials regarding Settings, and I've always came across the following issue.
Example:
Error: Error 3 'WindowsFormsAp plication1.Prop erties.Settings ' does not contain a definition for 'myVariable' and no extension method 'myVariable' accepting...Code:int myInt = Properties.Settings.[U]Default[/U].myVariable; Properties.Settings.[U]Default[/U].myVariable = 12; Properties.Settings.[U]Default[/U].Save();
Leave a comment:
 - 
	
	
	
	
Ugh now when i delete a button i get "FormatExceptio n was unhandled"-Input string was not in a correct format
but i fixed it by adding (prolly a bit inefficient but ehh...it worked :D)Code:cidx = Convert.ToInt32(c.Name.Remove(0, 3));
Initial code
"Fixed" codeCode:else cidx = Convert.ToInt32(c.Name.Remove(0, 3));
...Code:else { if (!c.Name.StartsWith("btn"))Leave a comment:
 - 
	
	
	
	
Waw amazing stuff man! :D Really awesome
I'll look into it tomorrow, the settings stuff looks very very helpful (was thinking ugh...save to file, then have to make a part for the program to know how to read from the file, seemed quite complicated)
Thanks a lot man for everything, really good stuff, and yea btw you explained great too (seeing that a newbie like me managed to copy the code and adapt it)Leave a comment:
 - 
	
	
	
	
About the AddMore....I feel so dumb :(
Adding the if worked btw :D awesome! One thing though, ugh...i'll just attach a pic :)
It's not a big deal anyway. If I click the "-" buttons in order from bottom to top all the buttons get removed in order = working as intended.
Thank you very much for your time :) I will try to implement the same thing with some panels and some text field. Got any ideas how I could...Leave a comment:
 - 
	
	
	
	
Also this
> Buttonz.exe!Win dowsFormsApplic ation1.Form1.c_ Click(object sender, System.EventArg s e) Line 71 C#
At the call stackLeave a comment:
 
No activity results to display
							Show More
							
Leave a comment: