|
It should be available by right clicking your project (the exe) and then selecting properties. This should open a nice window with some options for you. In the tab 'Application' you will find 'Resources'. Here you can set the icon file for the application.
|
|
|
|
|
Does anyone know how to allow a user to change the password in an MS Access database? My connection string (at least the path and password) is set programatically, read in from an encrypted file when the application loads, but I need to enable to user to change both the path and password for the database if necessary. Selecting the path is easy enough, but I'm not sure how to reset the password. Any help would be appreciated. Thanks.
|
|
|
|
|
not sure about this, but its probably not a good idea to use direct sql/access passwords for logging into a database.
a better approach might be to have a default login with public access. and then have a table with user names and password combination.
at the login screen, a query (using the default login) is done of that user table, and if a successful match is found then they are allowed to enter the application (with all queryies being run with the default access login).
changeing passwords would then be fairly simple, it would only be change to the table that holds all your users.
as far as tracking changes to rows, a unique session id can be created when a user logs in, and this ID can be used to track changes of data (like if someone decides to save somethign in the data base, the session id would be inserted with the row, and that session id would like to a user name)
not sure about best practices, but this approach seems resonable. not sure about concurrency issues with access when it comes to using a single username and password to log into a database for multiple users....
|
|
|
|
|
Hi everybody,
I use database oracle8i, and use System.Data.OracleClient to connect db, but when i insert, updat data, It can't save unicode font.
Do you what is problem? how to fix it?
Thanks!
xyz
|
|
|
|
|
You're cross-posting in multiple forums, which is a sin, but in this case, your second post was more clear that your first.
Font's don't get saved with string data, unless their descriptions are part of the string, like HTML. You'd have to serialize the font that your data is in, then save that data in a seperate column(s) of your table.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Is there a way to compile an application so that the files included in the application folder cannot be delelted unless the user uninstalls the program? Or, at least, is there a way to protect certain files from being deleted that may be essential to the program's operation?
|
|
|
|
|
My idea would be to NTFS file permissions on those files that need protecting. Set it up so that only the administrator has delete privs. All others would have read and execute?
How to do this from code you would need to do some googling.
|
|
|
|
|
If the user installed your application using Windows Installer (i.e., your Setup project), then they can delete all the files that they want in the Program Files area as long as you follow one simple rule: install the shortcuts to the application through your Setup project and NOT through programmatic means. If you do this, then that shortcut the user clicks on the desktop or in the start menu actually starts a process that checks the manifest for their installed program. If any "Vital" files do not exist, then Windows Installer will automagically replace them! Isn't that nice....
"we must lose precision to make significant statements about complex systems."
-deKorvin on uncertainty
|
|
|
|
|
Hi
I'm trying to find a way to understand how to know / found out forms/window's class-names.
I need it when I use:
<br />
[DllImport("user32.dll", EntryPoint="FindWindow")]<br />
static extern IntPtr FindWindow(string ClassName, IntPtr WindowName);<br />
For testing purposes I found that winamp's Classname is 'Winamp v1.x'. But how and where do you get to know that? :S
Maybe I'm missing something here, I'd like to know.
Thank you!
Sir Erugor
|
|
|
|
|
|
Thank you very much!
I just use the Spy++ app
Morten Kristensen aka. Sir Erugor
|
|
|
|
|
I have tried the following with no luck. I do not understand why NET RegEx does not handle this RegEx pattern. The pattern checks out fine in Regulator.
string testString = @"c:\temp\test.wav";
// get file extension
string pattern;
pattern = @".+\.[^.]+$";
System.Text.RegularExpressions.Regex regEx;
regEx = new System.Text.RegularExpressions.Regex(pattern);
System.Text.RegularExpressions.MatchCollection matchList;
matchList = regEx.Matches(testString);
string foundString;
foundString = matchList[0].Value;
// the output will be the same as testString: c:\temp\test.wav.
// the desired result is 'wav'
Console.WriteLine(foundString);
Happy Holidays
-- modified at 8:48 Friday 23rd December, 2005
|
|
|
|
|
hi redfish34,
try something like this:
pattern= @"(?<filename>.+)\.(?<extension>[^.]+)$";
then you can access the extension by matchList[0].Groups["extension"].Value
/cadi
24 hours is not enough
|
|
|
|
|
I got a "Unrecognized grouping construct" in both Regulator and VS 2003. But thanks for the effort!
The RegEx i am using came direct from http://www.regexlib.com/ and checks out fine in Regulator, so i do not understand why the NET 1.1 RegEx is not liking it. Maybe this is a bug with NET and i will be forced to parse the extension by hand. It is no big deal, i just don't like all these Microsoft headaches.
|
|
|
|
|
sorry, the braces got lost...
pattern= @"(?<name>.+)\.(?<extension>[^.]+)$";
(i should use preview before posting...)
/cadi
24 hours is not enough
|
|
|
|
|
Your mentioning of groups got me thinking. I tried the following code with my RegEx pattern:
foundString = matchList[0].Groups[1].ToString();
It returns the file extension "wav", which is what i wanted. I guess when one uses a capture expression in a RegEx then one must use groups to access the matches.
Thanks
|
|
|
|
|
there is one other solution using a non capturing group:
(?<=.+\.)[^.]+$
this will have only the extension in the resulting match.
/cadi
24 hours is not enough
|
|
|
|
|
|
you could skip regex and use FileInfo.
FileInfo fi = new FileInfo(filename);
string ext = fi.Extension();
Just an idea. Not sure what would be faster tho.
|
|
|
|
|
I did not notice the "Extension" property of the FileInfo object. That is definitely a better solution. Well, at least i got some RegEx practice from all this. I will be using RegEx extensively in my next project.
|
|
|
|
|
|
How Can I take backup of all table(with data) and store in XML file
Its Urgent plz?
|
|
|
|
|
I dont know if it's possible!
Maybe you should use a serializable file to save the objects..
VentoEngine corp.
Program your life ^^
|
|
|
|
|
You can pull the data you want to back up into a DataSet and then use the GetXml method to convert the Data into Xml.
|
|
|
|
|
Is this possible for entire database.
|
|
|
|