|
Bog wrote:
I'm just going to email you dude. my xml is dissapearing on this message board.
I hate that too! Thanx
"I dont have a life, I have a program." Also, I won't support any software without the LeppieRules variable.
|
|
|
|
|
Could someone tell me how to fire off a menu item click event from a UserControl. The menu is contained in the UserControls parent form.
Thanks,
Paul
|
|
|
|
|
if you have for instance a menuFileOpen_Click method for you file open on your menu and you wanted to use it for an open button you would just assign it to the buttons cick handler.
btnOpen_Click()
{
menuFileOpen_Click();
}
I hope that is what you ment.
|
|
|
|
|
I want to use DirectoryEntry class for my IIS.Both I have a problem in giving connection string to it.
In msdn said:
"LDAP://" or "IIS://" + path
But I don't know which pah I should give.Any suggestion?
Mazy
"And the carpet needs a haircut, and the spotlight looks like a prison break
And the telephone's out of cigarettes, and the balcony is on the make
And the piano has been drinking, the piano has been drinking...not me...not me-Tom Waits
|
|
|
|
|
Mazdak wrote:
want to use DirectoryEntry class for my IIS.Both I have a problem in giving connection string to it.
In msdn said:
"LDAP://" or "IIS://" + path
But I don't know which pah I should give.Any suggestion?
Quoted from MSDN:
The Path property uniquely identifies this entry in a networked environment. This entry can always be retrieved using this Path.
Setting the Path retrieves a new entry from the directory store; it does not change the path of the currently bound entry.
The classes associated with the DirectoryEntry component can be used with any of the Active Directory service providers. Some of the current providers are Internet Information Services (IIS), Lightweight Directory Access Protocol (LDAP), Novell NetWare Directory Service (NDS), and WinNT.
Note The portion of the Path that identifies the provider (precedes "://") is case sensitive. For example, "LDAP://" or "WinNT://".
The syntax for the Path property varies according to the provider. Some common scenarios are:
WinNT
Connect to a group on a computer. For example, "WinNT:// domain/ computer/ group ". If you are connecting to a local computer, "WinNT:// computer/ group ".
Connect to a user on a computer. For example, "WinNT:// domain/ computer/ user ". If you are connecting to a local computer, "WinNT:// computer/ user ".
Connect to services on a computer. For example, "WinNT:// domain/ computer/ service ". If you are connecting to a local computer, "WinNT:// computer/ service ".
Discover all domains on the network. For example, "WinNT:". The domains can be found by enumerating the children of this entry.
LDAP
Connect to a group in a domain. For example, "LDAP://CN= group-name, CN=Users, DC= domain-controller1, DC= domain-controller2,... ".
Connect to a user in a domain. For example, "LDAP://CN= full-user-name, CN=Users, DC= domain-controller1, DC= domain-controller2,...".
Connect to computers in a domain. For example, "LDAP://CN= computer-name, CN=Computers, DC= domain-controller1, DC= domain-controller2,...".
IIS
Connect to a Web directory. For example, "IIS://LocalHost/W3SVC/1/ROOT/ web-directory-name ".
"I dont have a life, I have a program." Also, I won't support any software without the LeppieRules variable.
|
|
|
|
|
Thank you very much.
Mazy
"And the carpet needs a haircut, and the spotlight looks like a prison break
And the telephone's out of cigarettes, and the balcony is on the make
And the piano has been drinking, the piano has been drinking...not me...not me-Tom Waits
|
|
|
|
|
When I do this to one of my projects
using System.Messaging;
I get the following error :
The type or namespace name 'Messaging' does not exist in the class or namespace 'System' (are you missing an assembly reference?)
What the heck is wrong with this picture ?
I am actually missing the namespace ?????
It's all over in the help system. It can't be missing!
Can someone please help me out ?
tia,
Pilgrim
|
|
|
|
|
You need to reference the assembly containing the System.Messaging namespace, in this case "System.Messaging.dll".
In VS.NET, right click on the "References" entry for that project and choose Add Reference. On the command line add "/r:System.Messageing.dll"
James
- out of order -
|
|
|
|
|
Hey Pilgrim,
Did u add reference to System.Messaging.dll from VS.NET Solution Explorer?
deepak
Deepak Kumar Vasudevan
http://deepak.portland.co.uk/
|
|
|
|
|
Hi all,
Is there a way to keep the same form (title bar, menus, etc.) but dynamically change the client area and event handlers? You know, like the MFC CView class.
I would like to have a SDI application that changes the view based on a menu selection. Do I have to create a different forms for the different views, but add the same title & menu?
|
|
|
|
|
What about using Forms inheritance?
Then just expose additional methods/properties to handle the delegates.
Cheers,
Simon
"From now on, if rogue states want to buy weapons of mass destruction, they're going to have to go on eBay," Mr. Bezos said.
|
|
|
|
|
Thanks for the suggestion !!
Paul
|
|
|
|
|
SimonS suggestion would work, but might be too much work in the end, rather than using Inherited Forms I'd go with a UserControl that implements the base functionality you need for the client area and event handlers (with the event handlers being marked virtual ).
Then for each 'view' create a new UserControl which derives from the base control created above. And replace the previous one that was there (unhooking/hooking up the event handlers as you go).
James
- out of order -
|
|
|
|
|
Thanks, sounds like a possible solution!
Paul
|
|
|
|
|
i face some problem when 2 thread trying to access a file at the same
time.
for thread X, it trying to access the file with:
-------------------------------------
b.Save("ref.jpg);//b is Bitmap object
-------------------------------------
while at the same time, the thread Y will trying to access the file
with:
------------------------------------------------------------------------
FileStream fs = new FileStream("ref.jpg", FileMode.Open,
FileAccess.Read, FileShare.Read);
------------------------------------------------------------------------
thread Y sometimes will halt at FileStream fs... line without execute
the next statement. i strongly suspect that it is because that i
trying to access the same file at the same time.
any suggestion in solving this problem?
thank you.
regards
yccheok
|
|
|
|
|
Although previous attempts to use the lock statement failed for me, it might help in your case
Hope it helps
"I dont have a life, I have a program." Also, I won't support any software without the LeppieRules variable.
|
|
|
|
|
i olso decide to use lock statement at first. (i hvnt try it out yet). may i know why previous attempts to use the lock statement failed for u?
thank you.
|
|
|
|
|
I think that the FileShare.Read flag may be at fault. Try the FileShare.ReadWrite flag instead.
Michel
It is a lovely language, but it takes a very long time to say anything in it, because we do not say anything in it, unless it is worth taking a very long time to say, and to listen to.
- TreeBeard
|
|
|
|
|
Has anyone written one? The DataGrid is being a pain for me, I just want something that I can use as a grid without all the data stuff. Mainly its the problems with interoperation between a DataGrid , DataTable (and all it's DataRow s), and a DataGridTableStyle just to get a simple grid display and editing of my data.
The ListView with details view looked good for a bit there, but then it seems you can't edit anything except for the first column, which makes sense—but, of course, doesn't work for me.
Any ideas? I checked CP pretty thoroughly, but perhaps there are other sites with controls that I am not aware of?
Thanks in advance...
-Domenic Denicola- [CPUA 0x1337]
“I was born human. But this was an accident of fate—a condition merely of time and place. I believe it's something we have the power to change…”
|
|
|
|
|
The DataGrid supports binding to several different types of sources. Sources implementing IList or IBindableList are just two of the possibilities.
I've heard good things about Janus System's grid, but I didn't know about it until after I made my purchase (below). Janus is supplying prizes to October's competition so I would look into them just for that.
I needed more control in the grid so I tried - and later purchased - Xceed's .NET Grid (www.gridcomponent.com[^]). Source to the runtime grid is available for purchase. While I was beta-testing the grid in August I ran across a couple snags, but my e-mails were answered shortly afterwards (I sent the e-mails around 4am EST, I had replies waiting for me when I woke up at noon).
Of course neither help you if you are looking for a free custom-grid solution.
James
- out of order -
|
|
|
|
|
James T. Johnson wrote:
Of course neither help you if you are looking for a free custom-grid solution.
Yes, I did kind of forget to mention that part, as this is simply a personal project that I'm not making money off of. I didn't know these things were such a thriving business. Oh well, it's not a big priority—I will continue to mangle the DataGrid as best as I can.
Thanks for the prompt reply, by the way.
-Domenic Denicola- [CPUA 0x1337]
“I was born human. But this was an accident of fate—a condition merely of time and place. I believe it's something we have the power to change…”
|
|
|
|
|
Domenic [Geekn] wrote:
I will continue to mangle the DataGrid as best as I can.
Unless you are dependent on using DataSet's and DataTables you can create your own IList implementations and set the grid's DataSource property to that.
This help topic, ms-help://MS.VSCC/MS.MSDNVS/vbcon/html/vbconInterfacesRelatedToDataBinding.htm[^], discusses the basics of data binding (such as is used by the DataGrid).
James
- out of order -
|
|
|
|
|
Basically I have two different controls which both need to raise the same event code. This would be easy if the control types were the same or used the same EventHandler, but in this case one is a CheckBox and the other is the ImageButton .
ImageButton uses the ImageClickEventHandler , not the normal EventHandler .
Currently I have had to make the two events and then they both really just go and run the same method.
But is there a way (a way of using delegates I do not know about?) of having them both go to the same event handler off the bat?
ta
Paul Watson Bluegrass Cape Town, South Africa Colin Davies wrote:
...can you imagine a John Simmons stalker !
|
|
|
|
|
Unfortunately no, unless you redefine the event in an inherited class, but that will be too much work. Best is just to make a common method and call that, and thats what you probably have already
Now here's a tip (maybe it will work for you): Instead of using a ImageButton, just use an LinkButton and add HTML to the Text property for the pic iow <img src="nudiepic.jpg"> . Then use the Click event of that. Now both are using the same event handler and Paul can be happy again.
Hope it works (all theory)
PS: start shouting for zim!
"I dont have a life, I have a program." Also, I won't support any software without the LeppieRules variable.
|
|
|
|
|
leppie wrote:
Now here's a tip (maybe it will work for you): Instead of using a ImageButton, just use an LinkButton and add HTML to the Text property for the pic iow . Then use the Click event of that. Now both are using the same event handler and Paul can be happy again
Lovely, good idea, thanks leppie.
leppie wrote:
S: start shouting for zim!
LOL! I have faith in the bokke... I have faith in the bokke... I have faith in the bokke... I have faith in the bokke... *Paul carries on chanting*
Paul Watson Bluegrass Cape Town, South Africa Colin Davies wrote:
...can you imagine a John Simmons stalker !
|
|
|
|