Skip to content

Visual Basic

Visual Basic Questions

This category can be followed from the open social web via the handle visual-basic@forum.codeproject.com

34.4k Topics 120.1k Posts
  • Very Hard Question ?

    question com regex tutorial
    1
    0 Votes
    1 Posts
    0 Views
    No one has replied
  • How do you detect if VB is in design mode or run mode

    design help question
    2
    0 Votes
    2 Posts
    0 Views
    D
    There is a property you can check that tells you. If Ambient.UserMode Then 'We are in Run mode Else 'We are in Design mode End IF -- David Wengier Sonork ID: 100.14177 - Ch00k
  • copying objects - newbie question

    question help
    3
    0 Votes
    3 Posts
    0 Views
    K
    Jeremy Falcon wrote: AFAIK you'll have to create your own copy contstructor. If you simply do a Object1 = Object2, VB will use a default property for the object. Actually VB will not do anything. There's no such thing as a deep copy in COM (which is what VB classes are). It will only do an QueryInterface() (if necessary) call and then AddRef(). ___________ Klaus [www.vbbox.com]
  • Immediate window in VS.NET ?

    csharp visual-studio question
    3
    0 Votes
    3 Posts
    0 Views
    K
    Uh, no. The debugger is the same as C#'s, and doing something like that would imply edit-and-continue, which is not supported. ___________ Klaus [www.vbbox.com]
  • VB Multithreading

    performance help
    2
    0 Votes
    2 Posts
    0 Views
    K
    Your code has so many problems I can't even begin to list them. Go here: www.powervb.com and buy the book. That's the only correct way to do threads in VB, period. Anything else is a hack, even if it seems to kinda work. ___________ Klaus [www.vbbox.com]
  • Printing problems

    question graphics
    2
    0 Votes
    2 Posts
    0 Views
    D
    Appstmd wrote: How can I tell to VB to print my text or my bitmap in the next page ? VB will do this automatically for text you print using the Printer.Print method, but it is best to do it yourself. For text: If Printer.CurrentY + Printer.TextHeight(text_to_print) > Printer.ScaleHeight Then Printer.NewPage End If Printer.Print text_to_print And for bitmaps: Dim picBitmap as Picture Set picBitmap = LoadPicture(filename_of_bitmap) If Printer.CurrentY + (picBitmap.Height * Printer.TwipsPerPixelY) > Printer.ScaleHeight Then Printer.NewPage End If Printer.PaintPicture ...... If you have the bitmap in a picturebox, just replace "picBitmap" in the above code with "Picture1.Picture" -- David Wengier Sonork ID: 100.14177 - Ch00k
  • Modal Form In Taskbar.

    json question
    8
    0 Votes
    8 Posts
    0 Views
    N
    Gosh! Instead of all this VB code, can't you just use something easier like C++? Nish My most recent CP article :- A newbie's elementary guide to spawning processes www.busterboy.org
  • (OLE) ToolBars of Embedded Object.

    com hardware help question
    1
    0 Votes
    1 Posts
    0 Views
    No one has replied
  • Good looking OLE

    question com hardware help
    1
    0 Votes
    1 Posts
    0 Views
    No one has replied
  • Using the internal speaker

    question tutorial
    3
    0 Votes
    3 Posts
    0 Views
    L
    Thx for the help with that. I think it will work. I'm not at the comp to test it on but I will find out in about an hour from now. :) Anyway I think the source coede to the DLL will help me in C++ as well. I've been meaning to learn how to write a DLL, that should help me a great deal. So I thank you two fold for your reply Quinn
  • Process Control

    help lounge
    2
    0 Votes
    2 Posts
    0 Views
    M
    I think (and this might be widely inaccurate in your case) that process control is a general term for controlling hardware processes (like keeping the waterlevel in a tank between some predefined min and max). I suppose you could use/extend the MSComm ActiveX control to handle the specific hardware you are using... /moliate
  • Condition Based Maintenance

    database com sysadmin algorithms
    1
    0 Votes
    1 Posts
    0 Views
    No one has replied
  • DLL Function in VB

    c++ com debugging help tutorial
    8
    0 Votes
    8 Posts
    0 Views
    V
    ATL objects are COM objects. You've got to create an instance of a class to use its functions. In general, you cannot use a member function of your C++ class without creating an instance of that class. It looks like you try to use member functions without creating any variables of that object's type. Volodya Orlenko, orlenko [at] hotmail [dot] com
  • find and replace (simple VBA)

    question help
    2
    0 Votes
    2 Posts
    4 Views
    V
    Here's a script that works: Sub Macro8() Dim fContinue As Boolean fContinue = True Dim Sel As Range Do While fContinue Set Sel = Selection.Range Selection.Find.ClearFormatting Selection.Find.Replacement.ClearFormatting With Selection.Find .Text = " " .Replacement.Text = " " .Forward = True .Wrap = wdFindAsk .Format = False .MatchCase = False .MatchWholeWord = False .MatchWildcards = False .MatchSoundsLike = False .MatchAllWordForms = False End With fContinue = Selection.Find.Execute(Replace:=wdReplaceOne) Selection.Start = Sel.Start Selection.End = Sel.End Loop End Sub Volodya Orlenko, orlenko [at] hotmail [dot] com
  • printing form content into a PictureBox

    2
    0 Votes
    2 Posts
    0 Views
    A
    Use windows api to capture form as BMP and display inside picture box control...? "An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
  • Securing (Licenscing) and ActiveX DLL

    com question
    2
    0 Votes
    2 Posts
    0 Views
    A
    I've never created a control in VB only VC. Runtime licenses are used in VC, isn't this available in VB...? "An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
  • Implementing Sound into VBasic Programs

    database help tutorial question
    4
    0 Votes
    4 Posts
    0 Views
    A
    DirectSound is another option "An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
  • Scrolling the ScrollBars

    question
    2
    0 Votes
    2 Posts
    0 Views
    J
    Try using the following API functions... ScrollWindow() ScrollWindowEx() I haven't tested it on an MDI form yet, but logically it should work. Also, don't forget to call UpdateWindow() afterwards, so the the client area is redrawn. Jeremy L. Falcon "The One Who Said, 'The One Who Said...'"
  • What is the way to add something from Flash5 to VB6??

    question com
    2
    0 Votes
    2 Posts
    0 Views
    T
    IF you have installed flash then you are half way through your problem. When macromedia Flash is installed, an activeX control called swflash.ocx. add this control in your project. you can use various properties and methods supported by this control to play your animation. There is no way through which you can pass any information from flash to vb6 or vice versa.
  • Visual Basic application----Please Help!!

    database help question
    3
    0 Votes
    3 Posts
    0 Views
    T
    It really depends how much time you can spend developing it on VB or any other software. VB is easy and you can easily find solution to your particular problem. 'Anonymous' is right in saying that you can use two tables in MS Acess, one for credit and other for Debit. have these two tables liked via a common key, like customer ID etc. Use SQL querty to retrive records from debit table corresponding to the credits.