|
Do the red, green and blue components match ?
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
When I do
DataGrid_Q.CurrentCell.Style.BackColor.ToArgb
then i get value as "0"
Can you plz give me a example of the same
|
|
|
|
|
The color is black, that's why it does not match.
DataGrid_Q.CurrentCell.Style.BackColor
in the debugger will expand to show the red, green and blue values, but it's already clear they do not match a green color. Therefore, your code is working, the cell is not green.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Thanks for the idea
Now it is working
The changes I made now are
- I was setting the color of whole of the row at a time
- When I was comparing I was comparing cell back color
- Now I changed the comparison to row back color and it worked
|
|
|
|
|
Great - glad it worked out for you.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hi there all
i have a problem that want you all to solve for me
i need some code to list all printer name that shared on the network
and then i want to print some document by select a specific printer name.
pls save me i need very Urgent
Regard from
spider anatha
|
|
|
|
|
I'm sorry, but no-one is going to do your work for you, that's not what we do here. Printing a document to a printer whose name you know is easy enough. As for discovering printers, if the drivers are not installed locally, you can't use the printer over the network, all you can do is try to install it. And if it is installed locally, then you will have the name in your local list of printer names.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
I am condemned for my sins to write in VB 6 for the next several whiles. Every time I fire up VS and select my project the IDE is populated with five modules I have absolutely no interest in seeing, editing, running, or anything else. I have closed them and saved the project more than once, but there they are the next time I start up.
Does anyone know where VS or VB saves whatever it is that makes these things appear?
Better yet, does anyone know how to make them stop appearing?
Thanx,
JimT
|
|
|
|
|
In the path that you save your project, delete all files whose extension is not as the known formats, e.g. if you have Form1.frm, then (if I remember correctly) Form1.frk or something like that is also created. Also one extra file is created with the name of your project, but without .vbw extension.
I can remember that if you delete these files, you would get what you want.
|
|
|
|
|
Thanks for your help. I tried it, but that didn't work either.
There were two files, as you suggested: .vbp and .vbw. I deleted the .vbw file and the annoying files quit appearing.
Thanks again!
JimT
modified on Tuesday, February 12, 2008 11:49 AM
|
|
|
|
|
I love the splitcontainer, but I need more than 2 panels. Any ideas of a good solution?
Thank you.
|
|
|
|
|
What about putting another SplitContainer inside one of the panels of the first SplitContainer?
|
|
|
|
|
Thank you.. yes, that is the way to go -- nest the splitcontainers inside each other.
|
|
|
|
|
Sorry, but I'm having trouble with what should be easy.
How to I detect that the user is holding down a key (F1 for instance) when the program first loads?
Thanks
|
|
|
|
|
Actually, it's quite difficult. Your application wasn't running when the key was pressed, so can't get a normal event notification that it was.
You'll have to use the Win32 API function GetAsynceKeyState[^] to find out if the key is still being held down. If I remember correctly, the virtual key code for "F1" is &H70.
|
|
|
|
|
Not hard at all actually... works perfect.. thanks!
|
|
|
|
|
Most people can't figure out how to do P/Invoke, let alone the binary math on the returned value. Glad to see you're not one of them!
|
|
|
|
|
It's much easier than that:
Private Declare Function GetAsyncKeyState Lib "user32" (ByVal KeyVal As Integer) As Integer
then:
Dim t As Integer = Me.GetAsyncKeyState(&H71)
|
|
|
|
|
Hi,
I am making a application which is communicate with another application on the same system.
i use config file for the remoting cofiguration.And its worked fine for few minutes.
But after some times an error is occured when try to raise event to the client from server. Error is "Object '/313ea683_ade8_4edd_9b25_d5a9566a83b4/st61eu4jxpjjvhgy1ts4zuuk_1.rem' has been disconnected or does not exist at the server."
I already to the lease to Time.Span=0 and also try Nothing.
But same problem is occured.
At the same time client is properly responding i.e. client is able to raise event at server.
can any one soultion for the same.please help about this??????????
Complete error message is -->
System.Runtime.Remoting.RemotingException was caught
Message="Object '/313ea683_ade8_4edd_9b25_d5a9566a83b4/st61eu4jxpjjvhgy1ts4zuuk_1.rem' has been disconnected or does not exist at the server."
Source="mscorlib"
StackTrace:
Server stack trace:
at System.Runtime.Remoting.Channels.ChannelServices.CheckDisconnectedOrCreateWellKnownObject(IMessage msg)
at System.Runtime.Remoting.Channels.ChannelServices.DispatchMessage(IServerChannelSinkStack sinkStack, IMessage msg, IMessage& replyMsg)
Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at EventsManager.SharedClass.WrapperClass.WrapperClassMethod(Object sender, EventArguments e)
at EventsManager.SharedClass.Hoster.CallClientEvent(Object Server, EventArguments e) in D:\Nitin Jain\RnD\RemotingRnD\Currently Working on this\Reminder By Remoting Intregrated with PDA - 080207\prjRemotingClient\Remoting Shared Class\EventsManager\Hoster.vb:line 143
at PDA.ProspectDatabaseApplication.frmActivityEntry.SaveRecord() in D:\Nitin Jain\RnD\RemotingRnD\Currently Working on this\Reminder By Remoting Intregrated with PDA - 080207\PDA-Remoting Server\ProspectDatabaseApplication\frmActivityEntry.vb:line 2063
|
|
|
|
|
Hi
As far as i know every MarshalByRefObject proxy has a limited lifetime which is by default 5 minutes. if you call a method on the object, the lifetime is increased by 2 minutes.
so if you don't raise an event for 2 minutes on the client, the proxy that presents the client to the server will die.
you can solve the problem by
a) adding an ISponsor that keeps the proxy alive
b) setting the lifetime in the InitializeLifetimeService method and use a more appropriate initial lifetime for the client proxy.
greets
m@u
|
|
|
|
|
thanks for ur reply.
But i already override InitializeLifeTimeService and set initializetime to 0 or nothing
So i think object should alive for the life time.
And if proxy object is dead, than how client can raise event at server.
Please do me fever...
|
|
|
|
|
We have to see the code you used to change the lease time. The lease, obviously, isn't being changed because it's still expiring.
|
|
|
|
|
i don't think the server is the problem. keep in mind that ANY MarshalByRefObject instance that is shared over remoting creates a proxy. so if your server can call a method on your client.
a) your client must be a MarshalByRefObject too (it'l create a proxy and everything...) so the problem might be that that proxy dies
b) i'm not sure if delegates are serialized or marshalled so there might also be a problem..
i'd suggest you take a closer look at the client implementation.
greets
m@u
|
|
|
|
|
Hello
I'm working with Visual Studio 2005 (VB)
When I polulate a listview (details) with a large amount of data (100 lines) the screen goes blank while filling the listview. The same goes when I fill a list of custom controls.
Is there a way to avoid this ?
|
|
|
|
|
How are you populatiing your list? If you are looping through a collection of some sort, you could try using Application.DoEvents() inside the loop .
Steve Jowett
-------------------------
It is offen dangerous to try and see someone else's point of view, without proper training. Douglas Adams (Mostly Harmless)
|
|
|
|