473,545 Members | 1,471 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How to identify a FolderBrowserDi alog?

I'm trying to create a program that dynamicly saves and loads path of a
FolderBrowserDi alog , but I ran into a problem. Since
FolderBrowserDi alog is not a Control, therefore it doesn't have
attribute such as Name. How do I get the name of a Component or unique
string to identify each FolderBrowserDi alog instances in the my form.
I tried GetHashCode() but that doesn't work out too well.

Any suggestion is apreaciated!!!

Thanks

Dec 7 '05 #1
4 1866
I don't understand why you have multiple instances of a
FolderBrowserDi alog. It's a dialog, meaning it is modal, which means that
only one dialog can be shown at a time.

Given this, why do you have multiple instances? Do you have a bunch of
different settings? If this is the case, I would just have a structure or a
class which holds the settings, and key those by whatever name you wish.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard. caspershouse.co m

<ho****@gmail.c om> wrote in message
news:11******** **************@ g44g2000cwa.goo glegroups.com.. .
I'm trying to create a program that dynamicly saves and loads path of a
FolderBrowserDi alog , but I ran into a problem. Since
FolderBrowserDi alog is not a Control, therefore it doesn't have
attribute such as Name. How do I get the name of a Component or unique
string to identify each FolderBrowserDi alog instances in the my form.
I tried GetHashCode() but that doesn't work out too well.

Any suggestion is apreaciated!!!

Thanks

Dec 7 '05 #2
I want to user multiple instances of the FolderBrowserDi alog so I won't
lose the "SelectedPa th" value between them

Dec 7 '05 #3
That's a waste of a good deal of resources just to store that. Why not
store the path as a string and then set the properties of the dialog when
you need to?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard. caspershouse.co m

<ho****@gmail.c om> wrote in message
news:11******** *************@g 49g2000cwa.goog legroups.com...
I want to user multiple instances of the FolderBrowserDi alog so I won't
lose the "SelectedPa th" value between them

Dec 7 '05 #4
thanks for your help!!!

Dec 7 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1852
by: Anja | last post by:
I have installed the new Visual Studio 2003 and implemented the FolderBrowserDialog. Everything works fine, if I open the FolderBrowserDialog before opening a Database Connection. If I open the FolderBrowserDialog after I opened the database connection no folders will be displayed in the FolderBrowserDialog. It's empty.
25
2184
by: | last post by:
Hi, The following code shows the FolderBrowserDialog = broken. FolderBrowserDialog folderDialog = new FolderBrowserDialog(); folderDialog.ShowNewFolderButton = false; folderDialog.ShowDialog(); Setting ShowNewFolderButton to false does bugger all. If I set this to false it is STILL shown. Genius.
1
14475
by: alf | last post by:
Hi, I am using a FolderBrowserDialog to allow the user to select a folder as follows: FolderBrowserDialog folderBrowserDialog1 = new FolderBrowserDialog(); folderBrowserDialog1.RootFolder = System.Environment.SpecialFolder.MyComputer; folderBrowserDialog1.SelectedPath = "D:\\"; folderBrowserDialog1.ShowDialog();
9
2413
by: hhh12347 | last post by:
FolderBrowserDialog crashes on my Windows 2000 computer. Here is a C# test program: using System; using System.Windows.Forms; public class TestForm : Form { FolderBrowserDialog folderBrowserDlg; OpenFileDialog openFileDlg;
0
1564
by: Tommy Clark | last post by:
I am using Microsoft Development Environment 2003 Version 7.1.3088 and .NET Framework 1.1 Version 1.1.4322 SP1. I have an MFC application that we have ported to .NET and have added the FolderBrowserDialog dialog to select a folder. This works fine if we do not preceed the dialog with a CString.Format call. When we have the call, the folder...
6
1778
by: John Krueger | last post by:
The FolderBrowserDialog control in my toolbox has vanished! I did not delibratly remove it and it is just not there anymore. I tried to add it back to the toolbox but there isn't even a .NET component (or even a COM) available to select from in the "Customize Toolbox" window! I noticed there is a RESET button on the "Customize Toolbox"...
12
5840
by: JohnR | last post by:
I have narrowed a problem down to a simple example. A form with two buttons. One EXIT and one FBD. The exit button does an "END" to end the application. The FBD button does a FolderBrowserDialog and nothing else. When I start the application and hit EXIT everything works fine. However if it display the FBD box (even if I don't pick a...
3
22302
by: antuantuan | last post by:
Hi. How can I initialize a FolderBrowserDialog choosing a particular RootFolder? I saw that FolderBrowserDialog has a RootFolder member, but it accepts only an Environment.SpecialFolder (but I don't want to choose a SpecialFolder for my FolderBrowserDialog). I hope I've been clear. Thanks in advance
2
3146
by: Marcel Brekelmans | last post by:
Hi, I'm trying to display a MessageBox after a FolderBrowserDialog. I see that it gets displayed, but not activated. The form is not in front and when I have some other forms open the MessageBox is hidden behind them. The problem seems to occur only after using the FolderBrowserDialog. Has anyone seen this before? Thanks
0
7465
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7656
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
7805
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7416
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7752
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
1
5325
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
3449
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
1
1878
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1013
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.