SEARCH YOUR SOLUTION HERE  

WriteFile (or CreateFile) Why doesn't this work

Copied directly from exaple book but not working.... i get is an empty 0 byte file Call to GetLastError directly after the call to WriteFile returns 0 (NO_ERROR) but no data sees to be written :-( Thx The ...

Posted On: Sunday 11th of November 2012 10:56:56 PM Total Views:  355
View Complete with Replies




Related Messages:

Importing a workbook with multiple worksheets to access   (168 Views)
So I have an excel workbook with multiple worksheets. I am trying to open it and import to access. I'm not quite sure how to do this. Would I open the workbook as an object If so I don't really know where to go from there. Or is there another way I can do this I don't really have any code yet because I'm not quite sure where to start. I googled it but it came back with a lot of SQL stuff and that's not really the direction I want to take with this. If anyone has any good reading material, I would really appreciate it!
check network connection   (204 Views)
Is there a simple way to check status of my network connection I need to produce a short program that I can drop in the startup folder which will check if the network is enabled when PC is turned on, ...
VB6 and access 2000. query works in access but gets error in VB   (201 Views)
I have created the query using one of the wizards in Access and it works. Formatted the query to use in a VB 6 project. However when I run it in VB I receive the following error run-time error '-2147467259' ...
vb- database- check box wont work. ??   (293 Views)
yo, i got a database, with tables in it. one of the fields in the table is s check box. i jave created a form in VB , which enables me to check or uncheck a field, but when i ...
Playing Windows Media Files in RB 5.5.4 does not work! Any ideas?   (137 Views)
, I am building an app that should be able to play both: Quicktime and WMV Files. I get the Quicktime thing working fine. But Windows Media does not want to work. Here is what I did: In the ...
Can't get sockets working   (231 Views)
Hi Group, I can't sort this problem out, I've a server and a client apps built by using RB Sockets. In the client I write something down to the editfield1 and then press the button, the text is sent to ...
Reading an Excel worksheet using ODBC from VB.NET   (136 Views)
How do I access an Excel Workbook from VB .NET using the ODBC driver I want to read Excel data into a DataGrid control on a web-page. Although ODBC says it can connect to Excel, it then asks me to ...
switching between workbooks   (216 Views)
I am starting my macro off with: dlganswer = Application.Dialogs(xlDialogOpen).Show This allows the user to pick which file they would like to open. My problem, however, is trying to switch back and forth between my workbooks. If I knew ...
Why won't this work?   (93 Views)
The code works fine in the W2K pro environment but why won't it work within a web page. I keep getting a cannot create object error. Is there a workaround so you can access Active Directory from within IE6
How to "Map" a Network drive using Visual Basic   (102 Views)
I have written the following VBScript program. It is stored into a file "map_drive.vbs". It successfully mapped to a network drive \\server1\data. Dim WshNetwork Set WshNetwork = WScript.CreateObject("WScript.Network") sPwd = inputbox("Enter password") WshNetwork.MapNetworkDrive "J:", "\\server1\data", false, "xyz_net\John", sPwd Msgbox "Drives ...
Common Dialog Control doesnt allow orientation from Landscape to Portrait programmatically   (236 Views)
, I am having a big problem with the Common Dialog control being used in a Windows app developed using VB6 SP6 running on XP and 98. When trying to print using the common dialog and set the common ...
Re: error trapping not working   (191 Views)
It doesn't work. If I do a debug.print Err.Number before I call the other function, it prints out the error number correctly, but once I call the other function and try to do a debug.print within that function I get ...
Program works in design mode but not after compilation, Any ideas?   (376 Views)
VB6 windows XP home I run a small app that has no forms in it, only a few BAS modules. It's function is to open a text file and load a few pieces of data into memory and then periodically ...
Access Autonumber works from VB with no code!   (132 Views)
I was informed by many-a-person that the Access autonumber is only going to work if you're adding records from within the Access environment. However, a test program I just made has disproved this. Using the ADO control, a DataGrid, and ...
How do I insert a specific worksheet using VB?   (248 Views)
, I need to insert specific Excel worksheets in one workbook into Word. I believe this should be straightforward, but I cannot find (or figure out on my own) how to reference the worksheet. Right now I have... Sub InsertSheet() ...
new web app development tool in the works   (329 Views)
I've found out something exciting, and I've been just dying to tell somebody... but I have to do it anonymously or I'd be in big troubel. I just found this Google group, I hope it's the right place for this ...
Check network connection   (257 Views)
How do I check if the network connection is enabled...
check for network   (267 Views)
How do I check if a network is enabled in VB6 I need to check at startup if a network is enabled & if so disable it....
compare emails through Subject doesn't work   (337 Views)
Hi , We have two accounts on which emails arrive. A lot of the time the same emails arrive at both accounts so we created this code to check the inbox of account2 with the deleted items of account1. We ...
A shutdown code that doesnt do the JOB   (317 Views)
Here a shutdown code i did in VB ...the problem is.. only logoff user and FORCElogoff works in it. i have win a XP home edition OS.. the code is as of follows: in form named form1, there are 4 command buttons : code ----- ----------------------------------------------------- Private Sub Command1_Click() ' Log Off USer Call Module1.ExitWindowsEx(LOGOFFUSER, 0) End Sub Private Sub Command2_Click() ' shut down PC Call Module1.ExitWindowsEx(SHUTDOWNPC, 0) End Sub Private Sub Command3_Click() 'Restart PC Call Module1.ExitWindowsEx(REBOOTPC, 0) End Sub Private Sub Command4_Click() 'FORCE log off odd.....supposed to forcereboot... Call Module1.ExitWindowsEx(FORCEREBOOT, 0) End Sub ------------------------------------------------------ code for module1----------- Public Const LOGOFFUSER = 0 Public Const SHUTDOWNPC = 1 Public Const REBOOTPC = 2 Public Const FORCEREBOOT = 4 Declare Function ExitWindowsEx Lib "user32" (ByVal uFlags As Long, ByVal dwReserved As Long) As Long ------------- see attachment for files for actual working , u must have both the form and module in the project u open in VB. ------------------------- Attached File(s) Shutdown.zip (1.09K) Number of downloads: 406