|
I have a combobox that is bound to the database. When I update this combobox, selected value changes.
Let's say that we have these values in combobox: AAA, BBB, CCC. The selected value is CCC. When the combobox
is updated, the selected value changes to AAA. It always changes to the first item in combobox.
Does anyone have any idea how to solve this?
Thanks
|
|
|
|
|
Hi, I am new to C# and im working trying some image processing, im using this bit of code to invert the pixels on an image grabbed from a video file, how do I extract the RGB values from a pixel in C# using the image buffer? Speed is of the essence...
Thanks in advance.
unsafe
{
byte* p = (byte *)(void *)pBuffer;
int nWidth = Width * 3;
for(int y = 0; y < Height; y++)
{
for(int x = 0; x < nWidth; x++ )
{
p[0] = (byte)(255-p[0]);
p++;
|
|
|
|
|
See this article[^], there are some examples how to extract and modify the RGB values of an image.
regards
modified 12-Sep-18 21:01pm.
|
|
|
|
|
This is how you get the color components of a pixel, specified by the x and y coordinates:
byte* p = (byte *)(void *)pBuffer;
p += (x + y * Width) * 3;
byte r = *(p++);
byte g = *(p++);
byte b = *p;
If you increase the pointer for the last component also, it will point to the next pixel. This is very useful if you access the pixels in sequence, as you don't have to calculate a new address for each pixel.
Despite everything, the person most likely to be fooling you next is yourself.
|
|
|
|
|
Hi All,
I have a field that I which to filter on using the Contains operator but currently its throwing a wobbly. Can anyone advise? Is this even a legal operator to use in the DataView?
filter = filter + "and fileName Contains '" + _freetext.ToString() + "'";
fileName is of type string. For instance the _freetext maybe something like "day" so things like "daytime", "sunday" would both be included.
Thanks in advance.
Jammer
Going where everyone here has gone before!
My Blog
|
|
|
|
|
Hi..
I deployed my widows project successfully( included SQL express, .net frame work, Database file, Project files)
I installed my .exe file (setup file) on client machine(system) its installed successfully.
But when i run that application ,i got the below error:
============================
Login failed for user 'sa'. The user is not associated with a trusted SQL Server connection.
<configuration>
<system.windows.forms jitDebugging="true"/>
</configuration>
When JIT debugging is enabled any unhandled exception will be sent to the JIT debugger registered on the computer rather than be handled by this dialog box.
=============================
please help me...
thanks in advance
|
|
|
|
|
How did you get this far and not know that the login you use needs to match the SQL Server installation you're using ? Also, why is your user logging in as SA ?
You need to create a user with just the permissions they need, and make sure that your connection string and the SQL Server instance you're using, match in terms of username/password/etc.
Christian Graus
Please read this if you don't understand the answer I've given you. If you're still stuck, ask me for more information.
|
|
|
|
|
hi Graus
actually we developed windows application using (Visual Studio 2008 C# & LINQ and sqlserever 2005 express edition).and i have to create setup and deployment for this project. i was added new project as "setup and Deployment" for my windows project .And i also included all the prerequisites to my project.exe layer.but main problem is "How can i deploy the database in Client machine ".
i tried this in client Machine :
it was installing All the Prerequisites in Client machine ,it was runnig succcesfully ,but it was showing "user is not trusted user" ,How can i solve this ,could u please help me,and i was strucking from last 3 weeks.
Thanks in advance.
|
|
|
|
|
im trying to change NumberDecimalSeparator but everytime i get error that its read-only instance.
here is all code i tried :
System.Threading.Thread.CurrentThread.CurrentCulture.NumberFormat.CurrencyDecimalSeparator = ".";
System.Threading.Thread.CurrentThread.CurrentCulture.NumberFormat.NumberDecimalSeparator = ".";
System.Globalization.CultureInfo.CurrentCulture.NumberFormat.CurrencyDecimalSeparator = ".";
System.Globalization.CultureInfo.CurrentCulture.NumberFormat.NumberDecimalSeparator = ".";
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y<p?jxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
You need to create your own culture and set the separator for that.
Dave
|
|
|
|
|
ok i did but how to set permanently ? here is my code that is working temporary
CultureInfo tmp_ci = (CultureInfo)CultureInfo.CurrentCulture.Clone();
tmp_ci.NumberFormat.NumberDecimalSeparator = ",";
System.Threading.Thread.CurrentThread.CurrentCulture = tmp_ci;
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y<p?jxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
I think you have to use SetLocaleInfo in kernel32.dll
Edit: MSDN[^]
Dave
|
|
|
|
|
In my project i want to implement sound recording what we have in windows xp so i want consume that.
Give me suggestion how to implement recording sound in .net any dll is avliable?
help me out
Ashok Nalam
|
|
|
|
|
Ashok Nalam wrote: Give me suggestion how to implement recording sound in .net any dll is avliable?
Is it a question or are you demanding it? Ever heard about Google? It has many pages for you to explore[^]
By the way, don't post in multiple forums, it's rude.
Giorgi Dalakishvili
#region signature
my articles
#endregion
|
|
|
|
|
hai all
i want to use the folloiwing code of line in my application.
FolderParam flParam = new FolderParam();
When i build this i am getting error like this.
The type or name space of folderparam cannot be found. are u mising assembly reference
can any one help me to slove this problem?
Regrds
Lijo
|
|
|
|
|
You need to add a reference to a dll that contains FolderParam class.
Giorgi Dalakishvili
#region signature
my articles
#endregion
|
|
|
|
|
Can u tell me in which dll folderparam class contains?
Regrds
Lijo
|
|
|
|
|
You are writing a piece of code which uses folderparam class and you don't know it comes from? In that case you even won't know what the class is for!
Giorgi Dalakishvili
#region signature
my articles
#endregion
|
|
|
|
|
i got tat code from google only...... So i dont know about tat class.
But the code which i got from google is very usefull for me.So if u dont mind can u tell me the dll of tat class?
Regrds
Lijo
|
|
|
|
|
1.Check your spelling before you make a post.
2.If you got code from Google, then Google can tell name of the dll for that class. If you think that I know all dll's and classes that they contain by heart, you are mistaken.
Giorgi Dalakishvili
#region signature
my articles
#endregion
|
|
|
|
|
Search for it in object browser!
|
|
|
|
|
When I use a NumericUpDown with Hexadecimal=false and a number that is too large or to small is entered, it is set to the corresponding limit.
With Hexadecimal=true however, the value is reset to the previous, correct, value, when a value too large or too small is entered.
I have tried to intercept the ValueChanged and various other events to get the same effect as with Hexadecimal=false, but there seems to be no situation in which I can read the entered value instead of the already reset value and adjust it manually.
Does anybody know a solution to this problem?
Thanks
|
|
|
|
|
Try to handle Validating or KeyDown events
Regards
|
|
|
|
|
Thanks for the reply!
I tried Validating, but that is only thrown, when the NumericUpDown gets the focus or looses it and in similar situations. It doesn't seem to be thrown right before the value is changed wrongly.
I also tried KeyDown, but wasn't able to intercept the value the NumericUpDown should take after the Key was pressed if there was no maximum and exchange it for the real value.
I solved my problem by enhancing a TextBox to take only hexadecimal numbers, adding a minimum and maximum etc. to it.
|
|
|
|
|
Hi,
is there any way to get the user name from an IP Addreess or viceversa in Same Network domain ?
Thanks in advance !!!
|
|
|
|