vb6

Windows 7 file problem

I am using VB6 SP6 This code has work correctly for years but I am now having a problem on a WIN7 to WIN7 network. It also works correctly on an XP to Win7 network. Open file for random as ChannelNum LEN =90 'the file is on the other computer on the network RecNum = (LOF(ChannelNum) \ 90) + 2 Put ChannelNum, RecNum, MyAcFile '(MyAc...

How to remove a row (item) from a VB6 ListView using a button?

How do I delete a row in a ListView. I need to select the row to be deleted and a command button will delete it with a alert message if you want to delete the row. What will be the code for that? ...

ActiveX Component Can't Create Object

Hi, I have VB6 ActiveXDLL called A.dll , I am referencing this DLL into my VB.Net Application. Now I am calling a function of A.dll in this project. A.dll function is referring to the function of B.dll ,C.dll ,C.dll further referrer to Z.dll and so on. when I am executing application it gives an error from B.dll that ActiveX component ...

VB6 OpenRecordSet has too few parameters?

I'm debugging an app with the following code: sql = myTable Set datTable.Recordset = myDB.openRecordset(sql, dbOpenDynaset, dbSeeChanges) where sql = "select * from table Order by Precipition,Date/Time" An error occurs on the second line saying "Run-time error '3061': Too few parameters. Expected 2". I believe the issue is the wit...

Does anyone know of a VB(A/6) example using GetLocaleInfoEx?

I thought I dug most of what I need out of the header files, but I keep crashing out. Here is the declare I tried using, but I don't think it's just an issue of the declare. I think I'm actually using it wrong. Private Declare Function GetLocaleInfoEx Lib "kernel32" ( _ ByVal lpLocaleName As Long, _ ByVal LCType As Long, _ ByRef lpLCDat...

find the duplicate and write it in log file.

...

How to properly remove all connections to an Access Database

Here's a snippet of VB6 code: myProjectDaoDB.Close FileCopy myName, TempFile where myName is the path of a database. This database is presumably closed in the first line. It seems that simply closing the database is not enough to properly remove all access to database since when I run the program, I get a run-time error of '70': Perm...

Sheridan SSDBGrid control having problems in a VB6 app

We've got an old VB6 application we wrote about 10 years ago. Back then we had no faith in data binding, so we did all of our own population of controls in code. (Long story, don't ask.) This application is one of our primary apps, so it gets used heavily. Back then, we purchased third party controls for various things, one of them b...

find duplicate insert into another table

I have a code that that loads my data into sql table. I want know that is there any way to load data into some other table if there is any duplicate value. if yes can you help me. My query is: "insert into t_DATA_DneFrc (RTN, AccountNbr, FirstName, MiddleName, LastName, Amount) values ('" & rcdDNE("RTN") & "', '" & rcdDNE("AccountNb...

how to find duplicates in recordset using vb6

Hi i have a recordset name rcdDNE. I read the rtn, accno, first name, Middle name, last name, amount, from text file and store it to the recordset. Now I want to store that values to database table. In my table accno is primary key. So before storing that into my table i want to find out if there is any duplicate accno in my recordset. I...

Remove Primary Key constraint from a column(sql server 2005)

How to remove primary key constraint from column. I have table t_data_dnefrc table. In that i have AccountNbr column which is primary key. I want to remove Primary key constraint for that column. ...

Windows 7: Automatic Logon Policy not working for winhttp API VB6 activeX control

I'm using WinHttp to do POSTs in a VB6 activeX control as follows Set WinHttpReq = New WinHttpRequest WinHttpReq.Open "POST", strUrl, False WinHttpReq.SetAutoLogonPolicy AutoLogonPolicy_Always aPostBody = 'Sometext' WinHttpReq.Send aPostBody UploadFile = WinHttpReq.ResponseText This works great on windows XP (all versions of IE), but ...

Make child window transparent to user input

Is there a way to make input "pass through" a child window and reach its parent? My problem is this: I'm making custom control with a label that can be formatted. So, rather than trying to re-invent the wheel, I added a RichTextEdit control and applied the WS_EX_TRANSPARENT extended window style. It looks like what I want, but there are ...

Is it possible to modify the settings from an .frm file in the executable?

I have a compiled VB6 application without access to the source. Is it possible to modify certain settings made in the .frm file in the executable? In my case I want to change the color of a control. I guess the general answer would be "no", but since it is possible with Delphi applications, because there the forms are stored as resource...

ActiveX component for SMTP proxy

Hi all, i'm looking for an activeX component which works as proxy and allows reading/manipulating smtp traffic. any ideas? thx ...

GetTokenInformation in Visual Basic 6

Hello, I am using GetTokenInformation as a part of the code that determines if the current thread is running as an Administrator. Anyway, I have a structure for TOKEN INFORMATION that looks like this: Private Type TOKEN_GROUPS GroupCount As Long Groups(500) As SID_AND_ATTRIBUTES End Type Then, I invoke GetTokenInformation like...

Control Properties in Visual Basic 6

Is there a way to ask for a control property in a loop?? I need somethig like this: For each p in control.properties if p = "Value" then msgbox "I Have Value Property" elseif p = "Caption" then msgbox "I Have Caption Property" end if next It could be done somehow? ...

assign table values to recordset and update with another recordset using vb6.

HI, I want to assign database table columns to recordset in vb6. And i want update them with the values that i have in my another recordset. Is that possible? Any idea or example code will be appreciated. Hoa assign the data from table to recordset? ...

Where do I download : VBRun60sp6.exe (which installs Visual Basic 6.0 SP6 run-time files) ?

When I go to the MS web page describing the latest VB Runtime Files list it directs me to what looks like the right download for VBRun60sp6.exe but when I actually download it it's VB6.0-KB290887-X86.exe which is just the OleAut32.dll update for VB6. I downloaded the VB6 IDE SP6 update but it installs directly to the Dev machine and I...

Is there any way to tell if the Windows Directory is writeable without actually writing to it to test?

I have some old vb6 code that checks to see if the Windows directory is writeable by WRITING to it then reading a value back. But... we have a virus scanner that's viewing that as suspicious behavior so I want to check it without touching it. Any Windows API calls for that? (Ideally for Win 98 and above) ...