dcsimg

Search:

Type: Posts; User: MarkT

Page 1 of 13 1 2 3 4

Search: Search took 6.76 seconds.

  1. Replies
    30
    Views
    1,138

    Re: Don't understand For...Next loop

    Yes, but in this case he says it never makes it inside the if statement and there is no other exit condition in his loop. In the code OP supplied, I see no other options.
  2. Replies
    30
    Views
    1,138

    Re: Don't understand For...Next loop

    There are only way that I can see the n=2 after the loop finishes is if UBound of SquaresAroundTarget equals 1.
  3. Replies
    12
    Views
    677

    Re: Issue with parsing

    It's been a while since I've played in VB6 but my gut reaction is why not ADO? I may be a little off on the syntax but it should be pretty close. Of course you still need to declare and instantiate...
  4. Re: Textbox scan of word and the word following that word

    Reading through the posts, I was wondering why InStr was the choice over splitting the string.
  5. Replies
    11
    Views
    605

    Re: Do While Loop True/False check doesn't work

    I think the problem is in the last check

    If blnSafe = True Then
    Label.Caption = "Safe"
    End If

    It only sets the label if you're safe. It doesn't clear the label if unsafe.

    If blnSafe =...
  6. Replies
    3
    Views
    309

    Re: Iterate Through textboxes

    Exit For is making the code drop out of the loop after it finds the first textbox that is not empty. Remove that line and see if you get the desired results.
  7. Replies
    11
    Views
    1,435

    Re: Random Number, no duplicates

    Probably more efficient ways of doing it but I used to do something like this when I need to randomly shuffle something.

    Private Sub Command1_Click()
    Dim i As Integer
    Dim col As Collection
    Dim...
  8. Replies
    10
    Views
    1,143

    Re: Assign dinamyc value to tetxtbox

    I don't know if Luca doesn't use control arrays because this is VBA and it is a limitation but in VB6 (not sure about VBA) you can iterate through the controls collection and set the text of a...
  9. Replies
    28
    Views
    1,700

    Re: SQL Query in order except first record

    Another option would be populate just the names from the database and the add the additional prompt to the combobox.

    'Code to populate users from database

    'Add a prompt as the first...
  10. Re: can somebody tell me how to accomplish this?

    Anything?


    MsgBox CalendarControl.DayView.GetCellNumber(Now)
  11. Re: can somebody tell me how to accomplish this?

    The function is expecting a date object. By using format, you are turning Now which is already a valid date object into a string.
  12. Replies
    10
    Views
    575

    Re: Problem storing Array into string

    Any reason for wanting to use an array? Wouldn't a simple replace work.

    findInvChars = (Date & " " & Time)
    findInvChars = Replace(findInvChars, ":", "/")
    findInvChars =...
  13. Replies
    15
    Views
    826

    Re: Deleting files in sub folders

    Pretty straight forward using the filesystemobject

    Private Sub Command1_Click()
    Dim fso As FileSystemObject
    Dim fld As folder
    Dim strStartingDir As String

    Set fso = New FileSystemObject...
  14. Re: HELP - Eliminating the Do..Until loop very slow completion

    Few thoughts...

    Right now it is unclear where goto VBSTOP takes you. I assume that it is bailing out of the loop. But even if it does, if you have 100,000 records in the Customers table and VBSTOP...
  15. Re: how to calculate Textboxes and sum in another textbox

    Give something like this a try.


    Private Sub txtDollar_Change()
    SumAll
    End Sub

    Private Sub txtFiftyCents_Change()
    SumAll
    End Sub
  16. Re: How to check if focus is on one of the textboxes?

    The quick and dirty way to do it would be using a timer.

    Option Explicit

    Dim m_ActiveControl As Control

    Private Sub Form_Load()
    Timer1.Interval = 50
    Timer1.Enabled = True
    End Sub
  17. Re: How to check if focus is on one of the textboxes?

    Not sure what you are trying to accomplish but the check in you button is always going to tell you to "Put cursor in text field". As soon as you click your button, the active control becomes the...
  18. Replies
    10
    Views
    811

    Re: Combo cascade

    In English, what does that error say?

    Never mind. I see the problem.
    In the Make_Word sub, comment out the line that is causing the error.

    Combo3 will not be populated until after an Item in...
  19. Replies
    10
    Views
    811

    Re: Combo cascade

    See if this get you there

    Dim DB As New ADODB.Connection
    Dim RS As New ADODB.Recordset

    Private Sub Form_Load()
    DB.Provider = "Microsoft.JET.OLEDB.4.0;"
    DB.Open App.Path & "\MADA.mdb...
  20. Replies
    7
    Views
    715

    Re: Resize textboxes at runtime

    Can you attach a sample project that's working with what you have so far?
  21. Replies
    39
    Views
    2,683

    Re: Emulate Double Click

    I would think this would work

    Private Sub List1_DblClick()
    Dim sShellLine As String
    Dim ret As Long

    MovieName = List1.List(List1.ListIndex) & "\VIDEO_TS.IFO"
    MovieName = "D:\DVD...
  22. Replies
    39
    Views
    2,683

    Re: Emulate Double Click

    """F:\Movies\16 Blocks\VIDEO_TS\VIDEO_TS.IFO"""

    Do you really need to warp this in quotes. Would this work

    "F:\Movies\16 Blocks\VIDEO_TS\VIDEO_TS.IFO"

    Either way, I have to believe that when...
  23. Replies
    39
    Views
    2,683

    Re: Emulate Double Click

    The ShellExecute() function returns the value 31 if there is no association for the specified file type. With that I find it hard to believe that on the machine where you are having this issue that...
  24. Replies
    39
    Views
    2,683

    Re: Emulate Double Click

    There must be some details we aren't getting here. If you can double click on the VIDEO_TS.IFO in windows explorer and it opens and "D:\DVD Movies\Dark Country\VIDEO_TS.IFO" is the proper full path...
  25. Replies
    39
    Views
    2,683

    Re: Emulate Double Click

    That's why people are suggesting ShellExecute instead of Shell.


    Option Explicit

    Private Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" ( _
    ByVal hwnd As Long, _
    ...
  26. Replies
    39
    Views
    2,683

    Re: Emulate Double Click

    ShellExecute is what you want. It will use the default application associated with the file extension to open the selected file. You will however need the full path to the file you are intending to...
  27. Re: Check array element values in immediate window

    You could also try the Locals Window to see the values of your array.
    140315
  28. Replies
    19
    Views
    2,183

    Re: VB6 Invalid Procedure Call or Argument

    If you run this you see the difference in what is being sent to the shell command.

    Private Sub Command1_Click()
    Dim msReportPath As String
    Dim sCookie As String
    Dim msServer As String
    Dim...
  29. Replies
    19
    Views
    2,183

    Re: VB6 Invalid Procedure Call or Argument

    Every comma you have in the shell command is being interpreted as parameter separator. So in your case it looks like you are passing the exe with an sCookie (command) parameter. Then the shell...
  30. Replies
    19
    Views
    2,183

    Re: VB6 Invalid Procedure Call or Argument

    You have way to many parameters in there for the shell function. The shell function accepts up to 2 parameters. The path of the exe is required and then there is the optional window style parameter....
  31. Re: [RESOLVED] trying to display Only the Year in another for can't figure out the ty

    What you really need to understand is what Data suggested. If you just did this one thing it would probably greatly reduce the amount of assistance you needed.
  32. Re: Is it Standard to use Active Directory with VB 6.0 in lieu of SQL Server?

    Once again, my take on OPs post is its not about database access. Instead I think they want to allow functionality based on authentication. That sounds like a front end thing.
  33. Re: Is it Standard to use Active Directory with VB 6.0 in lieu of SQL Server?

    Layout based on roles is where I thought AD had the advantage. It a simple check of group membership with no need for tables. As for web apps, the only ones I worked on used integrated authentication...
  34. Re: Is it Standard to use Active Directory with VB 6.0 in lieu of SQL Server?

    I think you and I are reading OPs request differently. I think you're seeing it as how do I authenticate to SQL Server and I'm seeing it as how do I authenticate to my application.

    If my take on...
  35. Re: Is it Standard to use Active Directory with VB 6.0 in lieu of SQL Server?

    The question has nothing to do with connection strings. It seem OP is asking if it's best practices to authenticate users and group access based on SQL Server tables or leverage Active Directory.
    ...
  36. Re: How to load data from txt file without space ?

    As has been pointed out, the 2 files are structured differently so you are going to have to adjust the content so they match. Here is some updated code that should work with the 2 files posted.


    ...
  37. Replies
    14
    Views
    2,184

    Re: [RESOLVED] Need Help with MSXML and XPath

    A quick Google search turned this up. http://xmltoolbox.appspot.com/xpath_generator.html
  38. Replies
    14
    Views
    2,184

    Re: Need Help with MSXML and XPath

    More than likely a node is not being returned by your XPath. See what happens if you try this in your code.

    If xDoc.selectSingleNode(txtNodePath) Is Nothing Then
    MsgBox "Node not found."...
  39. Replies
    2
    Views
    352

    Re: problem with repeated msgboxes

    Use Exit For

    For I = 1 To ListView1.ListItems.count
    If Val(ListView1.ListItems(I)) < 2 Or Val(ListView1.ListItems(I)) > 5 Then
    MsgBox "wrong values"
    Exit For
    End If...
  40. Re: After Update ,Total Hours Only Calculate 2 fields instead of 4 fields why?

    For the set, you may want to try something like this.

    SET [EnterTotal]=DateDiff(""n"", [EnterIn],[EnterOut]) + DateDiff(""n"", [EnterIN1],[EnterOut2])
Results 1 to 40 of 500
Page 1 of 13 1 2 3 4



Featured


Click Here to Expand Forum to Full Width