948 Posted Topics

Member Avatar for pooja.singh.3950

Yes, that's how it's supposd to work :) Why would you not want to do that? When you destroy an object, it's not supposed to be used anymore.

Member Avatar for nchy13
0
245
Member Avatar for paulkd

As usually is the case with this kind of question...It depends. I think the only good case nowadays (what with filestorage being quick and cheap) is when you need to control and maintain links to image metadata. Doing this in a database is much easier and provides a little redundancy …

Member Avatar for Reverend Jim
0
207
Member Avatar for BlackJax96

Please start your own thread. This question is marked solved and is over two years old. A new thread is more likely to be read and an answer to your question given.

Member Avatar for Ketsuekiame
0
3K
Member Avatar for fugio

`if(Convert.ToBoolean(dataGridView1.Rows[i].Cells["chkcol"].Value = true))` This statement will always return true as you are setting the Value to true in your statement. Was this was your intended result?

Member Avatar for Ketsuekiame
0
187
Member Avatar for Ketsuekiame

Hiya, I've just tried updating my profile with better information, however it fails to validate my MSN address and Twitter account. As a note, I hadn't actually updated these values, they were already in the system. ![395f67d86f7803faa07f84ddaffdff05](/attachments/large/3/395f67d86f7803faa07f84ddaffdff05.PNG "395f67d86f7803faa07f84ddaffdff05")

Member Avatar for Dani
1
338
Member Avatar for devourer17

What do you mean by "line spaces"? It could mean a couple of things in this context, could you clarify please? :)

Member Avatar for devourer17
-1
151
Member Avatar for abhi_1

Is there anything missing from the form that you haven't posted? That doesn't particularly look like it does anything. Have you tried just calling the action in the browser with no parameters to see what happens?

Member Avatar for Ketsuekiame
0
302
Member Avatar for manel1989

> Cue everyone telling you to use std::string instead of C-style strings. Or at least, `snprintf` ;) (If you are using the 2011 standards compiler)

Member Avatar for Ketsuekiame
0
211
Member Avatar for Galbatorix
Member Avatar for Galbatorix
0
152
Member Avatar for erinkay528

Honestly, that isn't very much and looks like boiler-plate code. Logically speaking, how to do your assignment is explained quite well in the assignment question, it even goes so far as to tell you what each method should do. I think I should re-iterate deceptikon's question, could you please be …

Member Avatar for Ketsuekiame
0
520
Member Avatar for titas.datta

My first suggestion is to try and subsection your code a little. Your code is complex and a bit difficult to read. If you split it out, it will be easier to understand. Secondly, your logic fails when `a` and `b` are of equal length when `b` is larger than …

Member Avatar for Ketsuekiame
0
408
Member Avatar for downtown1933

You will need to scrape the website for the Anti-CSRF token that is attached to the form and make the request as though you are a user, not a program that is using an API. If you search the forum for "FakeWebClient" you will find some code that will be …

Member Avatar for Ketsuekiame
0
301
Member Avatar for ss125

The only difference is how they behave if a session doesn't exist. `Session` will throw an exception if the session doesn't exists, whereas `HttpContext.Current.Session` will return null. If a session exists, they will both point to the same reference.

Member Avatar for ss125
0
225
Member Avatar for ss125

You need to use `in (val1, val2, ...)` be warned that this can be a farely slow operation, it's complicated to parameterise and only available in SQL 200 and above.

Member Avatar for ss125
0
209
Member Avatar for fuhanspujisaputra

You need to drop your `DISTINCT` keyword. Your Code column should be marked as Unique in the database, preventing duplicate entries. After that, simply add `[Description]` to your select statement. If you continue to use `DISTINCT` then you may end up losing data if you enter duplicates (it will only …

Member Avatar for fuhanspujisaputra
0
237
Member Avatar for DarthC#

I think it's akin to a `ListView`, but there is no automatic "explorer" control you can use out of the box.

Member Avatar for DarthC#
0
96
Member Avatar for johnrosswrock

Think of it in English first. What you need to do is: Select Event -> Get Sub events for this event -> Populate Sub Event -> Get Possible co-ordinators -> Populate Coordinators -> Get Price Info (store) Select Co-oridnators Enter Participant -> Calculate Price and Display This might translate into …

Member Avatar for johnrosswrock
0
220
Member Avatar for gennesis
Member Avatar for castajiz_2

You aren't invoking, you're just adding an event handler. You can call the method directly from the Tick event: if(this.InvokeRequired) this.Invoke(new paintEventHandler(Form1_After1s), new { sender, e });

Member Avatar for Ketsuekiame
0
197
Member Avatar for raaz999

There should be a hand gesture for click. It would be incredibly annoying if you only hovered it, especially accidentally, and then got stuck in a menu cycle of open and close because the detection wasn't working properly...

Member Avatar for Ketsuekiame
0
3K
Member Avatar for Diogo Martinho

The built in mechanism actually uses the country codes to select the correct resource file, with the default one having no country code. If you don't want to rely on built in (which doesn't always work) [This](http://geekswithblogs.net/shaunxu/archive/2010/05/06/localization-in-asp.net-mvc-ndash-3-days-investigation-1-day.aspx) is probably the best resource on the subject. Along with the [official resource …

Member Avatar for Ketsuekiame
0
113
Member Avatar for hanvyj

You can connect directly to the Exchange server using a service but you would need to know the user's account details to either A) Impersonate the user at the app level, B) Log the service on as a particular user and use Domain Authentication.

Member Avatar for hanvyj
0
111
Member Avatar for salesman91

Can you post your app.config file contents please. This hints that the connection string isn't in your config file.

Member Avatar for salesman91
0
315
Member Avatar for jnewing
Member Avatar for alan.davidson.566

For a brick that has reached the bottom, I'm presuming that the fall speed is 0? On that presumption; You enter your if statement on line 145. When you iterate your `for` loop, `spaceEmpty` will be set to false (because your block now occupies the space). This will cause you …

Member Avatar for alan.davidson.566
0
442
Member Avatar for fuhanspujisaputra

`string someNumberAsString = dReader.GetInt32(dReader.GetOrdinal("Code")).ToString();` is perfectly acceptable.

Member Avatar for fuhanspujisaputra
0
991
Member Avatar for adem87
Member Avatar for Ketsuekiame
0
106
Member Avatar for Franze

If at any point the code can be executed in the same **synchronisation context** as another thread (which may be a background thread) then you need to lock. Otherwise, don't bother. A sychronisation context (not to be confused with the object `SyncronizationContext`) could be best described as sections of code …

Member Avatar for Ketsuekiame
0
130
Member Avatar for Dani
Member Avatar for Franze

Your if statements mean that no code will ever execute. `if(boolTest != true && boolTest != false)` <-- This means "boolTest must be false AND boolTest must true" this is an impossible condition as they are mutually exclusive. The same applies with your `stringTest` object the only difference being that …

Member Avatar for Franze
0
165
Member Avatar for jacksmith655

Well, all that does is write out: `The folowing numbers:` You also have a brace the wrong way around at the end of the file, you never call your Max method and it will return after one iteration of the loop. Additionally, `v` is set to 1 and never changes, …

Member Avatar for tinstaafl
0
237
Member Avatar for Ryan_6
Member Avatar for sumitrapaul123

It might be better to use XML... <StyleSettings> <control name="text1"> <font size="12">Consolas</font> <forecolour>Red</forecolour> <backcolour>Yellow</backcolour> </control> <control name="text2"> <font size="11">Arial</font> </control> </StyleSettings> This is also much more readable :) You could also make sub-children: <control name="text1"> <font> <size>12</size> <name>Consolas</name> </font> </control> But this depends on your personal style. I prefer a …

Member Avatar for Ketsuekiame
0
251
Member Avatar for Franze

`SpinWait(numberOfIterations);` Spinwait is horrible and it should never be used. Even Microsoft say it's not useful for ordinary applications. If you're going to use SpinWait, don't even bother waiting at all. You may as well just iterate your loop repeatedly until you get the result you want.

Member Avatar for Ketsuekiame
0
202
Member Avatar for Franze

You only need to spawn the background thread once (your while loop will keep it running). I realise this is what your code actually does (thanks to the if statement) but you can tidy that up into a dedicated initialisation method. The button click event should only call Set on …

Member Avatar for Ketsuekiame
0
13K
Member Avatar for fugio
Member Avatar for crescendo
0
243
Member Avatar for AmrMohammed

As a simple explanation; it requests that the code you provide is executed on the thread that created the controls owner. This is typically the UI thread.

Member Avatar for Momerath
0
144
Member Avatar for ddanbe

Just thought I'd throw my 2p in. Be careful with lazy evaluation, you can easily cripple performance by re-iterating queries you already executed. IEnumerable<int> query = myIntList.Where(i => i > 0); long result = 0; // Executes Query foreach(int i in query) { result += query; } // Executes Query …

Member Avatar for Ketsuekiame
0
286
Member Avatar for TheSubby

Are you using WebAPI or WCF? URI Parameters is a strange way to call WCF (typically you'd use a SOAP object)...

Member Avatar for Ketsuekiame
0
269
Member Avatar for Franze

Thread.Sleep will *not* use CPU. It puts the thread to sleep so that it doesn't. What you effectively have there is a spin. Additionally, the resolution of the timer used for Thread.Sleep cannot guarantee you will recieve a 1ms sleep. A time slice is aproximately 15.6ms so at most, you …

Member Avatar for Ketsuekiame
0
3K
Member Avatar for Cameronsmith63

Try checking what process has your file locked with [Process Explorer](http://technet.microsoft.com/en-us/sysinternals/bb896653.aspx) Can't see anything obvious that would open a file and lock it in your code.

Member Avatar for Ketsuekiame
0
184
Member Avatar for GrimJack

Whoever imposed the 70mph limit needs to be taken out and shot! ;) On a more serious note, speaking as a Brit, knowing how tightly guns are controlled I feel safer here than I do when I visit the states. I'm still afraid of Mr. Burberry and his chavtastic warriors, …

Member Avatar for Agilemind
0
375
Member Avatar for ghosthunter1

Just because a company is new, it doesn't mean you should avoid them. Evaluate them against what they offer vs the price vs what you can get from other companies. If it does what you want and is in your budget, buy it using a credit card that offers you …

Member Avatar for ghosthunter1
0
99
Member Avatar for Jahliah

Don't really need to use Regex, String.Replace will work fine :) `string newString = "Deleting 11 files.ABC: Total Time = 01:16:30, Remaining Time = 00:00:00".Replace(' ', ',').Replace('.', ',');` Using regex does look tidier although the one listed above is incorrect. It should be: `string newString = Regex.Replace("Deleting 11 files.ABC: Total …

Member Avatar for Ketsuekiame
0
4K
Member Avatar for Ketsuekiame

Seems like there might be a problem with the editor not recognising code insertion when you're pasting code in the middle of a list. Below is a post displaying the problem http://www.daniweb.com/software-development/csharp/threads/458671/c-mysql-display#post1993030 I tried multiple ways to get that in there including: 1. Single Enter + Tab 2. Double Enter …

Member Avatar for Ketsuekiame
0
371
Member Avatar for wmc1956
Member Avatar for Karan_4

It's probably easier to explain with an example; public class BaseClass { public virtual void PrintName() { Console.WriteLine("Base"); } } public class NewDerived : BaseClass { public new void PrintName() { Console.WriteLine("New"); } } public class OverrideDerived : BaseClass { public override void PrintName() { Console.WriteLine("Derived"); } } ... BaseClass …

Member Avatar for Ketsuekiame
0
115
Member Avatar for Pilot122x

Well, you aren't going to get code without doing any of your own work. But to assist in you getting started; 1. Create your Pilot table. Remember to include a primary key, using the name or callsign is not a good idea, it needs to be something the database can …

Member Avatar for Pilot122x
0
273
Member Avatar for deceptikon

Animé are generally not children's cartoons. Some are targetted for that age group and some are not. The same applies for some Western cartoons. Would you let a young child watch Family Guy or American Dad for example? Some animé are definitely targetted at adults too, maybe young adult but …

Member Avatar for Ketsuekiame
0
202
Member Avatar for Dani

The End.