Search Results

Search found 593 results on 24 pages for 'vb6'.

Page 4/24 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Centering fonts in VB6

    - by James Musser
    How do you determine the length of a string of text in Arial Bold font, and then center it in VB6? If not here, can you point me in a direction where I might be able to find this information? We're not using a "label" or "picture box" do print the text to the screen. We are sizing the text on the fly, and allowing the user to scale the size of our application to their liking. We write the text to screen using code.

    Read the article

  • VB6 - View Code will not display code

    - by zSysop
    Hi all, This is probably a really dumb question but i'll ask anyway. I was wondering if there was any reason as to why a form wouldn't display its code when i click "view code" from the right click context menu in vb6? It was working awhile ago so i'm kind of stumped. Thanks

    Read the article

  • VB6 code for Reading/Writing Windows Registry values

    - by Clay Nichols
    I'm looking for a good example of reading and writing to the Windows Registry using VB6. Yes, I know there are lots of mediocre examples. I spent an hour googling and testing. Some were incredibly complex, others had only some of the functions, and almost none of it had been vetted in any way (voted on). Since Stack Overflow is intended to the canonical location for answers to programming questions, it seems reasonable to post it here.

    Read the article

  • Trace not working in a .NET DLL loaded from VB6 EXE

    - by Luis
    Hello I have a .NET DLL that writes to the Trace. But seems that when I call my DLL from a VB6 EXE the trace is not working. I have created an myApp.config file in the EXE folder with the trace configuration, but this does not solves the issue. I've also tried creating the Trace objects in code,but doesn't work: Dim _traceSrc as TraceSource= New TraceSource("myTraceSorce") Dim flListener As FileLogTraceListener = New FileLogTraceListener("myFileLogTraceListener") Dim tSwitch As SourceSwitch = New SourceSwitch("mySwitch") tSwitch.Level = _logLevel If I call my DLL from a .NET EXE it works, even if I dont have the app.config in the EXE folder, becusase I set it in code if the config is not found. Thanks

    Read the article

  • getting a blank data report vb6

    - by arvind
    Hi, I am new to vb6. I am working to create the invoice generation application. I am using data report to show the generated invoice. The step by step working of process is Entering the data in to Invoice and ItemsInvoice tables. Then getting the maxId using (Adodc) from the data base to show the last generated Invoice. Then passing the max Id as parameter to the data report which is showing the invoice according to the invoice id. It is working fine when I first time generate invoice. Now for 2nd invoice withou closing application I am getting a blank data report. For data report I am using dataenvironment. I am guessing the reason of blank data report is blank because there was no record for that Id. But actually the record is inserting in the database. Please help me.

    Read the article

  • Convert VB6 to C# use NDDE ? help

    - by tabvn
    i have a vb6 code i want to use http://ndde.codeplex.com/ , please help me convert to c# thanks Const TOPIC_SENSOR As String = "SeeLane|Sensor" Const TOPIC_GATE As String = "SeeLane|Gate" Const TOPIC_PIN As String = "SeeLane|Pin" Const ITEM_SENSOR_ACTIVATE As String = "Activate" Const ITEM_GATE_OPEN As String = "Open" Const ITEM_PIN_ON As String = "On" Const ITEM_PIN_OFF As String = "Off" Private Sub Form_Load() On Error GoTo NO_DDE_SERVER lblCar.LinkMode = vbLinkNotify lblLaneId.LinkMode = vbLinkManual lblName.LinkMode = vbLinkManual lblAuthorized.LinkMode = vbLinkManual lblFile.LinkMode = vbLinkManual lblConfidence.LinkMode = vbLinkManual lblType.LinkMode = vbLinkManual MsgBox "Ket noi voi thanh cong voi SeeLane !!!" Exit Sub NO_DDE_SERVER: MsgBox "Khong the ket noi voi SeeLane !(Xem chuong trinh co chay khong?)." Exit Sub End Sub Private Sub lblCar_LinkNotify() On Error Resume Next lblCar.LinkRequest lblLaneId.LinkRequest lblName.LinkRequest lblAuthorized.LinkRequest lblFile.LinkRequest lblConfidence.LinkRequest lblType.LinkRequest CheckAuthorized lblLaneId.Caption = lblLaneId.Caption + 1 End Sub Private Sub CheckAuthorized() Dim i As Integer i = lblAuthorized.Caption i = i + 1 If lblAuthorized.Caption = 1 Then lblPoke.LinkTopic = TOPIC_GATE lblPoke.LinkItem = ITEM_GATE_OPEN lblPoke = Chr(lblLaneId.Caption) lblPoke.LinkMode = vbLinkManual lblPoke.LinkPoke End If End Sub

    Read the article

  • Centralized error handling in VB6.

    - by AngryHacker
    I have the following method that all the error handlers call: Public Function ToError(strClass As String, strMethod As String) As String On Error GoTo errHandle ToError = "Err " & Err.Number & _ ", Src: " & Err.Source & _ ", Dsc: " & Err.Description & _ ", Project: " & App.Title & _ ", Class: " & strClass & _ ", Method: " & strMethod & _ ", Line: " & Erl Err.Clear exitPoint: Exit Function errHandle: oLog.AddToLog "Error in ToError Method: " & Err.Description, False Resume exitPoint End Function It turns out that because I declare an error handler in this function On Error GoTo errHandle, VB6 clears the error before I am able to record it. Is there a way to prevent the 'On Error GoTo errHandle' statement from clearing the error?

    Read the article

  • Howto troubleshoot vb6 dll 800a01ad error in c# application

    - by phq
    I have a dll that I created from a VB6 project that I am now using in a c# project. This has worked before but now when I try to return to the c# project to fix a bug, the program get a COMException stating roughly translated: Could not create an instance of COM-component with CLSID {085E3494-9F78-47D5-B0E6-FA460FD3CBED} from IClassFactory because of the following error: 800a01ad. So I try to create a new empty c# project with only one line in the main function: OurNamespace.OurClass foo = new OurNamespace.OurClass(); Which fails with the same error. I have registered the dll but that did not change the outcome of the problem. The problem only occurs on the machine I am currently at, still I'm interested to understand the problem so that I know how to fix it if it occurs on a customers computer.

    Read the article

  • Polymorphic Behavior in VB6

    - by Tom Tresansky
    I recently noticed the CallByName keyword in VB6. Since this takes a object, procedure name, "call type" and arguments array, can this be used to "fake" some types of polymorphic behavior? I can make 2 classes, class A and B, each with the same method Foo, and do: Dim list As New Collection Dim instanceA As New ClassA Dim instanceB As New ClassB Dim current As Object Call list.Add(instanceA) Call list.Add(instanceB) For Each current in list Call CallByName(current, "methodName", vbMethod) Next Anyone done this before? Problems? Horrible idea or genius idea? Implications? Unintended consequences?

    Read the article

  • EOF of excel in vb6

    - by Mark
    how do i write the code in vb6 in finding the EOF of excel file can anyone help me? i try to code this and it works.. --- Dim excelApp as Excel.Application Dim excelWB as Excel.Workbook Set excelApp = New Excel.Application Set excelWB = excelApp.Workbooks.Open("D:\Book1.xls") Dim xlsRow as Long Dim EOF as Boolean xlsRow = 1 Do While (EOF = False) If (excelWB.Sheets("Sheet1").Cells(xlsRow, 1).Value = "") Then EOF = True Else xlsRow = xlsRow + 1 End If Loop <--- this code is working, but the only problem is only the column 1 will be checked and the others is not. Can anyone help me on how to improve this code to check all rows and column of excel cells.

    Read the article

  • Fatal Error when using ADODB in VB6 on Windows Server 2003 SP2

    - by m.edmondson
    We've got a legacy app (VB6) which works fine on an old Windows Server 2003 box and has been for many years. Recently we've had to move it to a different physical location and in doing this we cloned the box with virtualisation and placed it elsewhere. In theory these two environments should be identical. On the new box however the app falls over when calling the RecordCount method of an ADODB.Recordset. I should say that I can successfully read the ADODB.RecordSet.Properties.Count property with no problem on the line before. The event viewer reports the following: Event Type: Error Event Source: Application Error Event Category: (100) Event ID: 1000 Date: 28/09/2012 Time: 11:15:27 User: N/A Computer: APP01 Description: Faulting application Control.exe, version 1.0.0.6, faulting module ntdll.dll, version 5.2.3790.4789, fault address 0x0002c6e4. I can only imagine there is something wrong with using ADODB within a virtualised environment. Any ideas?

    Read the article

  • how to validate username and password in vb6?

    - by srikanth
    i have created a database in mysql5.0. i want to display the data from it. it has table named login. it has 2 columns username and password. in form i have 2 text fields username and password i just want to validate input with database values and display message box. connection from vb to database is established successfully. but its not validating input. its giving error as 'object required'. please any body help i'm new to vb. i'm using vb6 and mysql5.0 thank you

    Read the article

  • VB6 debugging- doesn't go to error handling code.

    - by Can Ho
    Hi, I'm maintaining a vb6 project(ActiveX DLL). When debugging, the app run into the following function: Public Function HasValue(ByVal vValue) As Boolean On Error GoTo Err If IsMissing(vValue) Then HasValue = False ElseIf IsNull(vValue) Or Len(vValue) = 0 Then HasValue = False ElseIf isEmpty(vValue) Then HasValue = False Else HasValue = True End If Exit Function Err: If IsArray(vValue) Or IsObject(vValue) Then HasValue = True Else HasValue = False End If End Function and it stops at the line ElseIf IsNull(vValue) Or Len(vValue) = 0 Then vValue is a custom object, contains some properties(obviously, not null). Although I didn't put any break point there, the app stopped there and alerted error dialog saying that "Run-time error '438': Object doesn't support this property or method". We had error handling code but the app didn't run to error handling code. It just stopped at the line causing the error and I had to stop the application. Do you have any idea about that? Thank you very much.

    Read the article

  • What causes VB6 "Run-Time Error '5': Invalid Procedure Call or Argument"

    - by cundh2o
    In VB6, users occasionally receive this error and I am unable to reproduce it. Run-Time Error '5': Invalid Procedure Call or Argument I am referencing the "MSWord 10 Object Library" and sometimes this error occurs at some point after the application has opened MSWord 2002. However, this app has referenced the MSWord 10 Object Library for years, and this error just started occurring in the last few months. I am assuming I have introduced a bug somewhere, but no idea what might be causing it. The error does not occur very often and cannot be reproduced by a user when I am standing there. The error forces the app to totally shut down. Users are running Windows XP

    Read the article

  • Windows 7 UAC manifest file for some VB6 application

    - by Daniel
    Hi, all, I have an old VB6 application which should run on Windows 7 (with UAV set to the default level, 3 of 4 IMHO). It has the functionality to update itself, and Windows 7 is now complaining that it would modify the computer (At least windows 7 is right here). I was able to run it in Vista with some kind of manifest file, but this does not seem to work anymore (which is the intended behaviour if I think of it). The manifest file is this: <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0"> <assemblyIdentity version="1.1.0.24" processorArchitecture="X86" name="IKOfficeAppStarter" type="win32"/> <description>IKOffice Starter</description> <dependency> <dependentAssembly> <assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0" processorArchitecture="X86" publicKeyToken="6595b64144ccf1df" language="*"/> </dependentAssembly> </dependency> <trustInfo xmlns="urn:schemas-microsoft-com:asm.v2"> <security> <requestedPrivileges> <requestedExecutionLevel level="asInvoker" uiAccess="true"/> </requestedPrivileges> </security> </trustInfo> </assembly> The manifest can be found near the exe "IKOffice Starter.exe" and is called "IKOffice Starter.exe.manifest", which should be okey. Currently the Shield Icon has gone from my .exe, but when try to start the software, i get the message "Der angeforderte Vorgang erfordert höhere Rechte", or translated to english "the requested operation requires elevation". What can I do to stop windows to bug me anymore, so I can install this application on our clients computers. Hey, I already told Windows to run it as Invoker, so why is it still complaining?

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >