|
You need to Marshal the IntPtr to int or float.
|
|
|
|
|
Hello everyone,
When I use bu or bm to set a breakpoint into a process running C#, there is always error message like -- "Operation not supported by integrated managed debugging."
How to make WinDbg support .Net application debug?
(I made a search to find some similar questions, but not quite helpful.)
thanks in advance,
George
|
|
|
|
|
Acording to Wikipedia, there's an extension for debuggin CLR apps.
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.
|
|
|
|
|
Can you provide a link please? Or keywords to search?
regards,
George
|
|
|
|
|
|
Thanks Simon!
I have using .load to load the SOS package. And I have tried I can use extension commands like
!threads.
But when I use bu or bm to set a breakpoint, for example, bu Foo (Foo is a function in class FooUtility), there is error message like -- "Operation not supported by integrated managed debugging.
". How to solve it?
regards,
George
|
|
|
|
|
Sorry, I've no idea what the problem is. I'm no WinDbg expert.
I'd recommend getting a good guide, like the John Robbins book and starting with a simple app.
Simon
|
|
|
|
|
Thanks all the same, Simon!
Do you have any suggestions for a more specific forum?
regards,
George
|
|
|
|
|
|
Thanks all the same, Simon!
regards,
George
|
|
|
|
|
Hello,
I have a DataGridView with a DataGridViewCheckBoxColumn. I want to be
able to have the checkbox display in an indeterminate state, so I've
set the ThreeState property to True. However, I want the indeterminate
state to only be set programatically - whenever the user clicks the
checkbox, it should only toggle between Checked and Unchecked.
Now, this is the default behaviour of a standard CheckBox control - as
detailed in the CheckBox.ThreeState property documentation:
"the CheckState property value can only be set to the Indeterminate
value of System.Windows.Forms.CheckState in code and not by user
interaction"
How would I achieve this with DataGridView? I'm committing the changes
to the checkbox cells immediately by catching the
CurrentCellDirtyStateChanged event and calling CommitEdit as suggested
in the documentation for DataGridView. However, if I try catching the
indeterminate state in this event or in CellValueChanged, and setting
Value to CheckState.Unchecked, the cell's Value property changes but
the display does not update until the control loses focus or another
row is selected.
As this is the default for the CheckBox control, I'm sure it can't be
that difficult to get the DataGridView to do it. What am I missing?
Thanks in advance for your help,
Steven
|
|
|
|
|
Hi
I have a desktop application with a back-end as web service. Web service is hosted on server with Windows Authentication option.
All users do settings in provided setting form using desktop application and hit test connection and it succeeds for all except one user. When this unique user click test button he gets 401: access denied message. if he copy that web service URL in web browser and enters same credentials as in setting forms it works. So only the application fails to connect with web service.
Any help would be highly appreciated to resolve this issue.
Best Regards
Rizwan Bashir
|
|
|
|
|
Check the text encoding.
BTW why not hook up the debugger and see what happens?
|
|
|
|
|
Hi
Thanks for reply. its our client and we cannot force/request him to install .Net on his machine for us. So what ever we can do we have to use our development machine and then deploy on his machine.
if Text Encoding would have any problem then it must be with all users.
Best Regards
Rizwan Bashir
|
|
|
|
|
Rizwan Bashir wrote: if Text Encoding would have any problem then it must be with all users.
That's a bad assumption! Your use could fail because it has a 'ê' in its name and the server translates it incorrectly.
|
|
|
|
|
Hi
Thanks for reply and sorry I never thought of special character in username and password, I have mailed client about this and as soon as he will reply I shall definately update you.
Thanks again for a wonderful clue.
Best Regards
Rizwan Bashir
|
|
|
|
|
hi
it is not the problem, user has confirmed that his username is alphaNumeric like usr7980 and password is totally numeric. So encoding is no more applicable. Any other idea's
Best Regards
Rizwan Bashir
|
|
|
|
|
Rizwan Bashir wrote: Any other idea's
Not off the top of my head, sorry
|
|
|
|
|
Hi,
I have a question about static.
I have the following class:
public class Members
{
static public string Administrator = "A";
}
Because I would mark the variable Administrator as a Const, I changed the class to the following:
static public class Members
{
public const string Administrator = "A";
}
In my eyes, the behavior is the same in accessing the variable, only that you are not able to change the Variable.
Is this correct? Or do I need to use the keyword readonly instead of const?
Than I would have:
public class Members
{
static public readonly string Administrator = "A";
}
So, help me out by saying what is the best practice here.
Thanks.
|
|
|
|
|
The difference between read only and const is that one can be set in the constructor ( from memory ) A static class is syntactic sugar, the compiler just barfs if any non static elements exist in there. I use it, because it makes my intentions clear, but it really don't actually give you anything.
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 Guys,
What I'm trying to do is to update a label as numbers are being inputed in a textbox.
The label(lblBalance) is to decrease, or increase, as the value of the textbox(txtAmount) changes.
lastEnteredAmount is a string obj that holds what was previously entered in txtAmount.
lblAmtMax is a label that holds the max amount that the user can enter.
I put the code snippet below in the keyPress event of txtAmount. But i don't get the required result. What am I doing wrong?
.<br />
.<br />
.<br />
<br />
if (double.Parse(lblAmtMax.Text) < double.Parse(txtAmount.Text) || double.Parse(lblBalance.Text) < 0)<br />
{<br />
lblBalance.Text = "0.00";<br />
txtAmount.Text = lblAmtMax.Text;<br />
return;<br />
}<br />
<br />
double diffce = double.Parse(lblBalance.Text) + (double.Parse(lastEnteredAmount) - double.Parse(txtAmount.Text));<br />
lblBalance.Text = diffce.ToString();<br />
lastEnteredAmount = txtAmount.Text;
Please help!
He who goes for revenge must first dig two graves.
|
|
|
|
|
It's okay to validate the character input in the KeyPress event, but the info in the text box property txtAmount.Text is not changed until after that event. You probably want to validate the character entered in KeyPress, and if it is validated do the rest of your code in the TextChanged event.
|
|
|
|
|
Hi,
Is there any tools through which we can change the format of existing code......
Regards,
|
|
|
|
|
Tidy, Google it. Dont repost!
|
|
|
|
|
im creating application where the main purpose is to open multiple database,and migrate it in different databases. any idea will be a big help especially a simple code
|
|
|
|