[RESOLVED] how to make no gui application?
Thats the very basic thing & there should be like a template for this & after searching google & VBhelp file for like 3 hours I still cant find how to do it.
Let me get to point:
I want execute exe, it will decompress a file & exit.
I have code, it works. but the CMD console window keeps popping out every time I launch my exe.
Im a beginner, so explain for beginner please.
How can I make No gui application? Im using vb 2008 express
PHP Code:
Imports System
Imports System.Collections.Generic
Imports System.IO
Imports System.IO.Compression
Module Module1
Sub Main()
UncompressFile("1.gz")
End Sub
Public Sub UncompressFile(ByVal file)
'do stuff hire
End Sub
End module
Re: how to make no gui application?
If the CMD console windows pops out, its because you built a command line application, therefore it IS a no GUI application.
The CMD console is not a GUI (Graphical User Interface).
The only way I see, if you don't want anything to appear on the screen would be to create a windows form application and Hide it immediately.
vb.net Code:
Public Class Form1
Private Sub Form1_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Me.Hide()
'Do what ever you need to do here.
Me.Close()
End Sub
End Class
Re: how to make no gui application?
Just a guess...
What happens if you execute it like this?
myfile.exe > null
or
myfile.exe > C:\temp.txt
Re: how to make no gui application?
Quote:
Originally Posted by
Pradeep1210
Just a guess...
What happens if you execute it like this?
myfile.exe > null
or
myfile.exe > C:\temp.txt
I have no clue what do you mean? And not going to make a program to just execute it sry. im really pissed at vb right now.
@stlaural
Omfg and its as simple as that. No more annoying console window. Thank you.
Re: [RESOLVED] how to make no gui application?
Its not a perfect solution though, it works but its definitly not a perfect solution.
Still, if it does what you need it to do...
1 Attachment(s)
Re: [RESOLVED] how to make no gui application?
ok.. Please ignore my previous answer. I got your requirements wrong. I guess you want to double click and run your console application without any command prompt window appearing.
This is how you would run your console application without showing the command prompt window:
Just open your project properties and set the Application type to "Windows Forms Application". Rebuild and run your application. Now it should run without showing the command prompt window.
Attachment 76760
Re: [RESOLVED] how to make no gui application?
That is clearly a more elegant way to do it.