Search Results - VBForums

Search:

Type: Posts; User: Evil_Giraffe

Page 1 of 13 1 2 3 4

Search: Search took 0.05 seconds.

  1. Re: [RESOLVED] Case Sensitive Parameterize Querys

    Usernames would generally be expected to be case-insensitive: user1 would be the same user as USER1, for example.
    Passwords shouldn't be stored in plaintext anyway, so you'd expect them to be some...
  2. Re: How do you get your developed programs, "out into the world"?

    If you're talking about distributing the source code, then pushing it to GitHub would be an option.
  3. VS 2013 Re: Idea on how to application licensing VB.NET

    Ah, let's make a licence key by taking some information the user has, encrypting it symmetrically with a key that the user has, and call it secure, yes? (Hint: no)

    Let's not even get into the fact...
  4. VS 2013 Re: How to implement db password hashing +salting

    There is no way to have the application running on a user's computer and prevent them from retrieving the password used to connect to the database.

    I would normally recommend having your...
  5. Re: What is the best way to read from a text file?

    If you add the text file to your project, then in its properties make sure the Build Action is set to "Content" (if you add a New Item to the project and select Text File this should be the default I...
  6. Replies
    36
    Views
    634

    VS 2013 Re: Multithreaded class

    If you are dealing with Tasks, you don't need any background threads. You create a Task and attach continuations to them - a continuation is just a function/sub that will run when the Task completes...
  7. Replies
    22
    Views
    519

    VS 2013 Re: Preventing SQL injection

    In mod_databaseLogin you're initialising a field when you initialise the type (Dim reader As OleDbDataReader = command.ExecuteReader()) with an expression that relies on command field that isn't...
  8. Replies
    7
    Views
    283

    Re: Safer Add Column

    If your users can alter the data structure you're in something of a bind here with a relational database. You've got a few options:

    1) Alter the table structures based on the user specifying the...
  9. Replies
    22
    Views
    519

    VS 2013 Re: Preventing SQL injection

    The first and second steps should be combined: convert to the appropriate (VB) type in your VB code (or use controls that return that type as you mention) and pass those converted values as query...
  10. Replies
    7
    Views
    283

    Re: Preventing SQL injection

    Um, no I don't think that will work, although likewise I haven't tested it. Generally you can only parameterize the data parts of a query, so table names and column names are out. However, if you're...
  11. VS 2010 Re: New to multithreading - help required

    This is the exact scenario for which BackgroundWorkers were provided. I would look into those before handling the threading yourself.
  12. Thread: unit test

    by Evil_Giraffe
    Replies
    11
    Views
    290

    VS 2012 Re: unit test

    Assuming the point of "letting it simmer for a few days" is so you can forget about how it works internally and approach it fresh for the tests, why not write the tests before those internals have...
  13. VS 2013 Re: [RESOLVED] How to unit test this method?

    Yes, it's messy but it's the point where your abstractions hit the metal of the frameworks, so it is always going to be messy. The fact that you have the abstraction so that all your business logic...
  14. Thread: unit test

    by Evil_Giraffe
    Replies
    11
    Views
    290

    VS 2012 Re: unit test

    It would help to give a bit more of an idea what your form is going to do. First thing to note is that you will get pushed by your test to write your logic separated from the UI, so it will help to...
  15. VS 2013 Re: How to unit test this method?

    Given that this is an implementation of an interface that abstracts away the notion of a message box, then my first thought of Humble Dialog is irrelevant.

    So I'd suggest in this case, it's...
  16. Re: Feedback requested about my unit testing strategy

    Testing the internals of a unit makes it not-a-unit-test. The test is against the externally visible behaviour of that unit. So, if your unit is a class, you wouldn't need access to the private...
  17. Replies
    12
    Views
    436

    Re: Help With Object Oriented VB

    For all the object oriented solutions presented, I am seeing a curious lack of the Class keyword. None of these solutions are an object oriented approach. Just sayin'. It doesn't matter, they're...
  18. Replies
    7
    Views
    298

    Re: Usng 4.5 task factory async await

    No, with Tasks you call ContinueWith and pass it a method to invoke when the result is available. No events involved.
  19. Replies
    7
    Views
    298

    Re: Usng 4.5 task factory async await

    If you're using Tasks, you don't need to async/await.
  20. Replies
    5
    Views
    209

    VS 2010 Re: Creating asynchronous sockets

    Um, yes. the async model is going to have callbacks. That's the point. It's conceptually harder to get your head around but once you have mastered it, you can free yourself of most of your threading...
  21. VS 2010 Re: Object Reference not Set - even if it is?

    Oh ho. Threading + error exhibiting only some of the time == Race Condition. I'd, as ever, heartily suggest you use the asynchronous socket API and stay entirely on a single thread. This would...
  22. Replies
    5
    Views
    319

    VS 2010 Re: [RESOLVED] Class hierarchy question

    If DoSomeStuff has no implementation in A and the implementation must be supplied by an inheriting class, you can mark the method as MustOverride rather than have an empty implementation:...
  23. Re: Generic class with multiple type constraints

    I think you're confusing generic constraints with generic type parameters. When you declare a variable as List(Of Integer), the "Integer" bit isn't a constraint.
  24. VS 2013 Re: Unit Testing Private Sub and Private Functions

    There are also significant schools of thought that would suggest the use of Default Instances, Application.DoEvents, Thread.Sleep, ... Doesn't mean those constructs aren't things that appear to work...
  25. VS 2013 Re: Unit Testing Private Sub and Private Functions

    Okay, I can see several different responsibilities in there which may be why you're finding it hard to test. What's the test that you're trying to write now? Pretend that the sub/function is public,...
  26. VS 2013 Re: Unit Testing Private Sub and Private Functions

    Unit Testing private subs/functions is the incorrect thing to do. You should only unit test externally visible behaviour. Sometimes you might not know how to write a test for the effect that your...
  27. Replies
    9
    Views
    362

    Re: 3d Rectangle

    Why are you defining a 3D rectangle? A 2D rectangle is useful because then you're talking about a block of pixels on screen, so special handling for that is somewhat obvious. It isn't so obvious in a...
  28. Replies
    8
    Views
    277

    Re: raise event question

    Sometimes, yes. Not in this case, however. What on earth is the problem with extracting a method from the handling method and calling it? Whether you expect the code to change again is somewhat...
  29. VS 2013 Re: When is the best way to load initial data (MVVM, IoC, Unit testing)?

    What is in control of constructing the VMs? If you have a controller to deliver them, then it makes sense to do it there. However, if you have one piece of generic code that loads any VM required...
  30. VS 2010 Re: Need a code to delay the execution of the code

    Just adding a delay won't work. You'll still raise a TextChanged event as each character is "typed" into the TextBox. If you delay long enough that the barcode scanner finishes typing you'll still...
  31. VS 2013 Re: Tic-Tac-Toe: What data structure would you use?

    A 3 by 3 array may seem the most natural way of representing this, but the best model is not the most realistic, but the one that most effectively answer the questions of the domain. You may find...
  32. Replies
    6
    Views
    332

    VS 2013 Re: "Online" Game help

    That is a massively insecure way of arranging things. Exposing the database directly to the network is a no-no. Having clients directly access the database is a no-no. Embedding credentials in the...
  33. Replies
    8
    Views
    251

    VS 2012 Re: Event handling problem

    You've got two fields typed as Example in your Form, T which you assign a new instance of Example to in its initialiser, and Log. You call the Test() method on T, but the Log_UpdateStatus event...
  34. VS 2013 Re: Stuck on the most basic of problems - Reference to a non-shared member...

    Well, yes there is. And you've actually nailed why that is earlier:



    The nested class does have access to the outer class's fields and properties (local variables are not the same).



    ...
  35. VS 2010 Re: Deleting Items In A List In A For...Next Block

    The problem is that you think you've created a temporary list, but you haven't. You've created a second way of referring to the same list. TempList is the same list as bmpList, so iterating over...
  36. Replies
    8
    Views
    321

    VS 2005 Re: Textbox - Currency without "$"

    Or, having played with this a bit more... supposing you want to keep the rest of the current culture's settings... (e.g. european countries' use of "," as the decimal point, etc, which the above code...
  37. Replies
    8
    Views
    321

    VS 2005 Re: Textbox - Currency without "$"

    Sounds like you need a custom format string so that you can specify different behaviour for positive and negative numbers ( http://msdn.microsoft.com/en-us/library/0c899ak8.aspx#SectionSeparator )....
  38. Re: I can't discover how to 'Cast' a Form.

    I think you've gone down a wrong path here. Can you show us the methods that call the PlaceMe method? It definitely feels like you're solving the wrong problem here.
  39. Replies
    17
    Views
    483

    Re: Public Class Issue ?

    What's happening there is that you're now defining a Class inside a Sub, which is not allowed. Perhaps you mean this:

    Module Module1
    Sub Main()
    Console.Writeline("Hello")
    ...
  40. Replies
    17
    Views
    483

    Re: Public Class Issue ?

    The concept in your OP does not, as you've discovered, work. I'm not sure what it is about the code that you're trying to achieve. In what way does the class "not work"?
Results 1 to 40 of 500
Page 1 of 13 1 2 3 4



Featured


Click Here to Expand Forum to Full Width

Survey posted by VBForums.