|
Not really programming question:
When debugging in Visual Studio 6 you can skip lines of code to be executed by placing the cursor where you want to start and pressing Ctrl+Shift+F10 (can also be used to repeat the same code over and over). I`m debugging a C# program now in Visual Studio 2005 and Ctrl+Shift+F10 does not work. I can only see options to step in a function, step out or run untill the cursor, but no option to skip lines or place the cursor a few lines prior to the current... Is this option not available in C#?? If it is, can anybode tell me the shortcut-key?
Thanks,
Davy
|
|
|
|
|
Place curosr in line of code which u want and press F9 then u have breakpoint in that line (this is in VS.NET 2005)
|
|
|
|
|
I don't think that there is a shortcut key for that. Just grab the arrow indicating the next instruction and drag it up or down.
---
b { font-weight: normal; }
|
|
|
|
|
Thanks that`s what I was looking for.
|
|
|
|
|
In C# on .NET 2.0, how do I use external files for a custom Section that do NOT have a relative path (meaning "c:\Config\Files\" for ex.).
Second, I am trying to save a hashtable (with string keys and string values) to that external file and then load it but I could not find a simpel way to do that using classes in the System.Configuration namespace. Did I miss something or is the KeyValueConfigurationCollection class the only way?
Thanks,
|
|
|
|
|
hi all, i have some confusion about the functions and stored procedures in sql server i hope u will clear my cofusion...my question is..what is the diff between sp and function in sqlserver and where to use this function and where to use this sp? plz..give some example....
Regards,
ayyp
|
|
|
|
|
have a look this article
http://www.dotnetspider.com/qa/Question22237.aspx
|
|
|
|
|
thank,u cleared my doubt
Regards,
ayyp
|
|
|
|
|
It's my pleasure
|
|
|
|
|
How can i destroy the child form object from MDI form in C#
|
|
|
|
|
Hi there,
A little quistion.
I have a Form that contain's a textfield and a Button.
If the button is pressed a new form opens (the old form stays open too)
The new form contains a datagrid where the user can select a customer.
On the dubble click of the row the form closes and should put this value into the textfield.
the select row is not the problem.
the dubbelclick isn't a problem as wel.
the problem is how can i fill the textbox when dubbelclicked on the row.
I can pass the data between the forms. and usaly i use the initialize component or formload to fill up the forms.
But in this case he doesn't reopen the first form.
|
|
|
|
|
on double click event :
Form1 frm1 = new Form1();<br />
frm1.TextBox1.Text = selectedrow text
|
|
|
|
|
that opens a new form and that is not exactly what i want cause he loads my populate textbox event which is defined by initialzi components.
|
|
|
|
|
Form1 frm1 = new Form1();<br />
frm1.TextBox1.Text = //value
this code doesn't open form as u see it's declared new instance of Form and then via that instance it's refered to text of textbox.
|
|
|
|
|
oke open was maybe a bad word to use..
but if i use this he will go to the initialize components section of the form and i wan't to skip that part i really don't want him to do this..
cause there he loads an event wich contains data from a previous form. any way he doesn;t load this 2 times.
|
|
|
|
|
If i want to bypass this with a if else sting.empty he says that he cannot covert string to bool.
|
|
|
|
|
i used to get the last value (in order to insert new record) like this
(select max(IdColumnName) from TableName) , but it seems its not the best
approach to do this , why??
why (select @@identity) is consider as the good way ??
thank you all
Tamimi - Code
|
|
|
|
|
Getting the largest id is not a safe way to get the id of the record. If another user added a record at the same time, you will get the wrong id. Consider this scenario:
:: User 1 adds a record, which gets id 42.
:: User 2 adds a record, which gets id 43.
:: User 1 gets the highest id, which is 43.
:: User 2 gets the highest id, which is 43.
Now both users think that they added the record with id 43.
Using @@identity on the other hand is completely safe. A user will always get the last id that was created in the database session, e.g. with the same database connection.
---
b { font-weight: normal; }
|
|
|
|
|
you know.. the best way to undersatand this is to try it;)
i will try to check it on a small application
thanks
Tamimi - Code
|
|
|
|
|
Guffa wrote: Using @@identity on the other hand is completely safe
In SQL Server, you never used to be assured to 100% always get the right id with @@identity. So in sql server 2000 they added a built in fuction called SCOPE_IDENTITY() which is AFAIK 100% guaranteed to get you the right ID.
Current blacklist
svmilky - Extremely rude | FeRtoll - Rude personal emails | ironstrike1 - Rude & Obnoxious behaviour
|
|
|
|
|
Correct. I mentioned the scope_identity function in the previous thread:
http://www.codeproject.com/script/comments/forums.asp?forumid=1649&mode=all&userid=3050175&select=1532206&df=100&tid=1531522#xx1532206xx
AFAIK there is only a difference between @@identity and scope_identity() when you are using triggers that uses inserts.
@@identity will always return the last id created in the session, but if the trigger also inserts a record you will get the id of that record instead of the id from the insert that caused the trigger to run.
---
b { font-weight: normal; }
|
|
|
|
|
I created a screensaver project, used all the default settings. When the project is completed, it works fine with two images (SSaverBrackground,SSaverBrackground2). I cannot find A way to add more images.
Any help is greatly appreciated
Using VS 2005
|
|
|
|
|
i have a dataset that is filled from a webservice. The dataset will contain a table with 2 columns. What's the code to bind the DysplayMember property to one of the Columns and the Value member to the other one??
rzvme
|
|
|
|
|
u can use
comboBox1.DataSource=Dset.Tables["table name"];
comboBox1.DisplayMember="column1 name";
comboBox1.ValueMember="column2 name";
rahul
|
|
|
|
|
tried that too: error:An unhandled exception of type 'System.ArgumentException' occurred in system.windows.forms.dll
Additional information: Could not bind to the new display member.
rzvme
|
|
|
|