User Profile

Collapse

Profile Sidebar

Collapse
Bum
Bum
Last Activity: Feb 27 '08, 05:48 PM
Joined: Jan 17 '08
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • Bum
    started a topic referencing C++.net Code from VB.net
    in .NET

    referencing C++.net Code from VB.net

    Hello,

    First off let me preface that I'm not a C programmer.

    I have a solution that contains both C++ project and a vb project. I reference the C++ project in my vb project so I can use the C code in my vb. I create routines inside a class in C++, then build it. This works all well and good until I have a *variable in my routine, when I try to use the routine in my VB I get this error:

    'MyRoutine'...
    See more | Go to post

  • sorry...forgot a line,

    Code:
    Contextstr = "-mapid " & ContextID & " "
    See more | Go to post

    Leave a comment:


  • Hi,

    I use the shell statement and the hh.exe which reads chm files.

    Code:
    (vb)
    
    Help = App.Path & "\My_Help.chm"
    XXX = Shell("HH.EXE " & Contextstr & Help, vbNormalFocus)
    hope this helps,

    B
    See more | Go to post

    Leave a comment:


  • Bum
    replied to Maze Walls
    Looks like your forgetting the height of the picture:

    Code:
     VB
    If Keycode = vbKeyDown Then 
        If Shape1.Top + shape1.height <= Game.ScaleTop Or _ 
        Shape1.Top = Wall1.Y2 And _ 
        Shape1.Left < Wall1.X1 And _ 
        Shape1.Left + Shape1.Width > Wall1.X1 Then 
    Else 
    Shape1.Top = Shape1.Top + 100 
    end if
    hope this helps

    B
    See more | Go to post

    Leave a comment:


  • Bum
    replied to VBA MSComm troubles
    Hi dbrother,

    you have a loop where you're looking for a colon. Are you sure a colon is supposed to come through? Why don't you try to say

    code[vb]
    strchar = ""
    do until strChar <> ""

    this way, if anything comes through you can see it.

    also, the reason your program might seem like it's hanging up is b/c of this loop. You need to use DoEvents in the...
    See more | Go to post

    Leave a comment:


  • Bum
    replied to Stretching the Image on MDI Form
    Hi Mahesh,

    Look at

    Screen.TwipsPer PixelX
    Screen.TwipsPer PixelY

    You get the size of your screen this way.

    if you want, you can do below, add three pictureboxes to mdiform adn make them the same size as the mdiform like

    picture1.height = mdiform1.height
    picture1.width= mdiform1.width

    [CODE=vb]
    Public Sub Setup_Image(Fil eName)
    ...
    See more | Go to post
    Last edited by Killer42; Feb 15 '08, 02:37 AM. Reason: Added CODE=vb tag

    Leave a comment:


  • Bum
    replied to Timed Random number in 2005 Express
    why don't you

    Code: ( text )

    ' This variable will be the loop counter.
    Private counter As Integer

    Private Sub InitializeTimer ()
    ' Run this procedure in an appropriate event.
    counter = 0
    Timer1.Interval = 600
    Timer1.Enabled = True
    End Sub

    Private Sub Timer1_Tick(ByV al sender As Object, ByVal e As System.EventArg s) Handles Timer1.Tick...
    See more | Go to post

    Leave a comment:


  • Bum
    replied to Access rights!!!!
    are you adding a reference to the Microsoft Office [version] Access Library?
    See more | Go to post

    Leave a comment:


  • Bum
    replied to Forms List
    You could keep count with a global variable.
    See more | Go to post

    Leave a comment:


  • Bum
    replied to Help with loop and matrix in VB6
    Use a bubble sort:

    [CODE=vb]Sub BubbleSort(List () As Long, ByVal min As Integer, _
    ByVal max As Integer)
    Dim last_swap As Integer
    Dim i As Integer
    Dim j As Integer
    Dim tmp As Long

    ' Repeat until we are done.
    Do While min < max
    ' Bubble up.
    last_swap = min - 1
    ' For i = min + 1 To max
    i = min + 1
    ...
    See more | Go to post
    Last edited by Killer42; Feb 15 '08, 02:26 AM.

    Leave a comment:


  • Bum
    replied to will not work
    Not sure what you're trying to do here

    if you're trying to close an application use killprocess

    hope this helps,

    b
    See more | Go to post

    Leave a comment:


  • I also have code to put a textbox in front of the grid being used and then it replaces the data. If you post your email, I will email you the whole project.

    Hope it helps,

    B
    See more | Go to post

    Leave a comment:


  • 'herer's an example of getting the data from a csv and putting in a flexgrid:
    'keep in mind this was mad for MY csv file, you must customize it for yours.

    Public Sub Initial_Read_CS V()
    Dim strMiddleInitia l, strLastName, objUser
    Combo1.Clear
    On Error GoTo errhandler 'Resume Next

    strExcelPath = "\Review.csv"'p ut your path here


    '...
    See more | Go to post

    Leave a comment:


  • Bum
    replied to opening a file
    Yes,

    commondialog1.o pen

    but make sure you add a commondialog reference to your toolbox first.
    See more | Go to post

    Leave a comment:


  • nevermind, I like Kadgar's way better! haha
    See more | Go to post

    Leave a comment:


  • Hi,

    You could read the excel file in, then write it out in csv (comma separated values)

    to read look at this post:

    http://www.thescripts. com/forum/thread651944.ht ml

    to write just use the

    open 'filename' for input as #1
    Write #1, variable, variable, variable
    'this writing will output into a csv.
    close(1)

    hope this helps!

    ...
    See more | Go to post

    Leave a comment:


  • Bum
    replied to Searching textbox?
    use something like

    dim tstr as string 'the string you are trying to find

    ''look for word
    dim i
    i = instr(textbox.t ext,"message")

    'look for space after word
    dim k
    k = instr(i + 1,textbox.text, " ")

    'look for space after first space, and if j returns zero then the word you want is the last word

    dim j
    j = instr(k + 1,textbox.text, "...
    See more | Go to post

    Leave a comment:


  • Bum
    started a topic Trying to read a C dll and convert some code

    Trying to read a C dll and convert some code

    Hello all,

    I have a C dll I need to tap into and some C code to interpret to vb.net 2005, but am so far unsuccessful. I just get the generic "runtime has encountered a fatal error at XXXXXX memory". I think my prob is passing the variables. Also, I know the * refers to pointers, but not sure how to interpret them. Hope someone can help...

    'Here is the C Code:


    [CODE=c]enum XXXXStatus {StatusUnknown...
    See more | Go to post
    Last edited by Killer42; Feb 14 '08, 01:44 AM. Reason: Added CODE tags

  • Bum
    replied to dll from another project in visual studio 2005
    in .NET
    Sometimes when it says "file not found", it's not the dll that's missing, but a component that makes up the dll. Look at the dlls dependencies using someting like DLLExplorer. The dlls dependencies are on your pc, but not the client's. Hope this helps.
    See more | Go to post

    Leave a comment:

No activity results to display
Show More
Working...