
Darren66
Members-
Posts
21 -
Joined
-
Last visited
Content Type
Profiles
Forums
Blogs
Events
Articles
Resources
Downloads
Gallery
Everything posted by Darren66
-
Joe Cheers for the link. That deals with MDAC not being correctly installed but to the best of my knowledge it was installed fine. I found the answer on another forum which I will post here should anyone else find it useful. "You can bypass the Windows Component Update if the individual required updates have been installed. In some cases, Windows Component Update may continue to report failures even though the individual components have been successfully installed. Note, however, that this is only appropriate if all required components are installed. Visual Studio .NET will not function properly without these components. To bypass Windows Component Update for Visual Studio .NET 2: 1 /Insert Visual Studio .NET CD1. 2/ Close any programs triggered by autorun. 3/ Click Start, click Run, and then run the following command: X:\setup\Setup.exe /NO_BSLN_CHECK where X is the CD drive"
-
Dear All I am attempting to install vs.net 2003 professional edition onto my windows 2000 machine. The first stage is to get the Prerequisites setup and the setup package is telling me it needs to install MDAC 2.7 SP1. I then click 'install now' but I always get 'The following component failed to install MDAC 2.7 SP1' and thus the setup fails. I have installed mdac 2.7 manually myself and used an app called 'Component Checker' to verify MDAC has installed; which it has but I still get the same failure message every time. Any suggestions ?? Apologies for such a boring question!
-
I read a forum post here (I don't have the link to hand) which discussed the various methods for making an application inactive after 30 days if the user hasn't entered an unlock code. One method that was suggested was creating a hidden file in the windows directory which could be used to indicate whether the program was paid for or not, rather than using registry entries. My intention was to do something similar...
-
I want to write a piece of code that creates a file in the windows directory when the user performs a certain action. The problem I have is not creating the file but correctly referencing the windows path. What is the best way to do this? I'm hoping that there is something similar to Application.Path except for the windows directory.. If anyone can point me in the right direction it would be appreciated. Thanks
-
I've got an VB application that works just fine on my devlopment machine (as of course they always do) which is running XP, but when I tried to run the application on a different machine I got the following error: System.ArithmeticException: Overflow or underflow in the arithmetic operation. at System.Drawing.Font.Initialize(FontFamily family, Single emSize, FontStyle style, GraphicsUnit unit, Byte gdiCharSet, Boolean gdiVerticalFont) at System.Drawing.Font..ctor(String familyName, Single emSize, FontStyle style, GraphicsUnit unit, Byte gdiCharSet) at WindowsApplication1.Form3.InitializeComponent() at WindowsApplication1.Form3..ctor() at WindowsApplication1.Form1.Form1_Load(Object sender, EventArgs e) at System.Windows.Forms.Form.OnLoad(EventArgs e) at System.Windows.Forms.Form.OnCreateControl() at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible) I have installed the dotnet framework on the new machine which is running Windows ME. Can anybody shed any light on this error for me?? I've looked around a bit but can't find much info..
-
I have been using the code that Derek posted here some time ago to check for multiple instances of my application however it seems that although it works perfectly in Debug Configuration when I switch to Release Configuration it stops working... Has anyone else noticed this or is it just my machine!! Cheers
-
I've been having a look at using DotFuscator but I cannot fathom it! The walkthroughs and examples in the help documents talk about opening up your .xml file. Well my windows forms app produces alot of files but none of them .xml Does anyone know how to use it??
-
Is it possible to call a webpage that has a form on it and get the form's action to run automatically, having used a variable to populate the forms field? <Form Action=name.php Method=Post> <Input Name=FirstName Value='username'> <Input Type=Submit> </Form> (My webpage is on an Apache server and I'm using php if it makes any difference..)
-
I don't have administrative rights at the moment but I will get them and attempt what you mentioned. Many Thanks
-
I am considering building an application which would include various users being able to ftp files to a website. I don't particularly want to give the users the login/password for ftp access to the site but at the same time I know it's not a very good idea to hardcode passwords! Can anyone suggest what the best method would be to get this type of security? Would Dotfuscator have any effect as (I am no expert on this) I think password could be intercepted when it leaves the application??
-
At the end of the routine I have a Thread1.Suspend to which I have now added Thread1.Sleep. I still get the 100% problem unfortunately. From the timer event I have blnKeepRunning = True and then Thread1.Resume. I've been looking at this for too long and I'm not thinking straight but do I need the suspend and resume? Otherwise the Do / While loop only run once.. While blnKeepRunning '-Work, work, work... ... '-Now, sleep a bit. blnKeepRunning = False Thread1.Sleep(100) Thread1.Suspend End While
-
Volte (or anybody) As per your suggestion I put the code within the thread in a loop and use a boolean to switch it on or off. Basically the thread is alive whilst the Timer is running. This works absolutely fine. However I noticed that if I started another thread after I had started Thread1 the CPU went upto 100% (from about 15%) and stayed there until the app was closed. I decided to do a few tests looking for contentions without solving it so I deccided to start from the bottom up. For Thread2 I put a simple msgbox("Hello") command in the new thread and started it (having already started thread1). This also takes the CPU upto 100% and it stays there until I stop the application. Any ideas?? Am I going mad?
-
Finding the size of an online directory
Darren66 replied to Darren66's topic in Directory / File IO / Registry
I've been using the WinInet API's to access the Internet and put files in the directory specifically: InternetConnect, InternetOpen, FtpPutFile. This all works fine. But I couldn't find anything for determining the directory size. It seemed like it should be fairly simple, but it's got me! -
I want to find the size of a directory which I know will have no subdirectories. On my local machine the following works fine: Imports System.IO Public Function DirSize() As Integer Dim d As New DirectoryInfo("c:\Darren") Dim Size As Long = 0 Dim fis As FileInfo() = d.GetFiles() Dim fi As FileInfo For Each fi In fis Size += fi.Length Next fi Return Size End Function However what I really need is to find the size of a directory that resides on the internet and I can't seem to get it to work.... Any suggestions?
-
Cheers Volte Could I ask your advice on this - I am calling the thread with a Timer event and what may occur is that the timer event fires for the second time before the first thread has finished executing. Therefore what I wanted was some sort of 'If Thread1.IsAlive Then Exit Sub' line at the beginning of the Timer event to avoid running the rest of the Timer event code until the thread has finished. If I create a new thread each time the Timer fires I could get some big backlogs build up. Could you point me in the right direction? Many Thanks
-
I have created a thread in my code to deal witha lengthy download from the net so the GUI remains reponsive whilst the download takes place. However - I want this thread to run numerous times as the file online changes quite often. I put the Thread.Start command in a timer and everything works fine the first time the code runs. The second time the code runs I get a ' ThreadStateException' error. Having consulted the manual I can see that my thread is starting, running and then stopping succesfully BUT that a thread cannot return to the running state once it has stopped. Can anybody tell me how to get round this problem?? Many Thanks
-
Divil Typically I think I've just managaed to get it working although at this point I'm not quite sure how. I hope I haven't wasted your time. Many Thanks.
-
I ran this code through the upgrade wizard from VB6 to VB.net and this was the result. I noticed that the data types have been changed from Longs to Integers however I changed tried changing them back to Longs with no success. The first piece of code is from my form and is the line which attempts to make the connection. <code> hConnection = InternetConnect(hOpen, "ftp.mysite.com", INTERNET_INVALID_PORT_NUMBER, "user", "password", INTERNET_SERVICE_FTP, dwSeman, 0) </code> <code> Public Declare Function InternetConnect Lib "wininet.dll" Alias "InternetConnectA" _ (ByVal hInternetSession As Integer, ByVal sServerName As String, ByVal nServerPort As Short, ByVal sUsername As String, ByVal sPassword As String, ByVal lService As Integer, ByVal lFlags As Integer, ByVal lContext As Integer) As Integer Public Declare Function InternetCloseHandle Lib "wininet.dll" _ (ByVal hInet As Integer) As Integer Public Declare Function InternetOpen Lib "wininet.dll" Alias "InternetOpenA" _ (ByVal sAgent As String, ByVal lAccessType As Integer, ByVal sProxyName As String, ByVal sProxyBypass As String, ByVal lFlags As Integer) As Integer </code>
-
Or let me rephrase that : It seems to me that InternetConnect API Works in VB6 but not VB .NET Any suggestions?
-
I am a newbie to VB.net and have been reading manuals but would appreciate it if somebody could point me in the right direction. I want to click a button and connect to the internet if not already connected - something which I achieved in VB6 with wininet.dll. Is there a better way of doing this now in .net??