New topic: 

GUI to Console Application

<http://forums.realsoftware.com/viewtopic.php?t=47502>

         Page 1 of 1
   [ 3 posts ]                 Previous topic | Next topic          Author  
Message        p0wn3d          Post subject: GUI to Console ApplicationPosted: 
Thu Apr 04, 2013 1:37 pm                                 
Joined: Sun Oct 28, 2012 4:54 am
Posts: 187
Location: Herts, UK                Hi can somebody advise how I can convert 
this into a console application. Unfortunately i can only find a single console 
app in the examples folder shipped with 2012 r2

Dim http As New HTTPSocket
dim myvalue as string = (http.Get(" http://checkip.dyndns.com/";, 30))

Dim rx as New RegEx
Dim myMatch as RegExMatch
rx.SearchPattern = "(?s)(?<=<body>).+(?=<\/body>)"
myMatch=rx.search(myvalue)

if myMatch <> Nil then
  System.Log(System.LogLevelInformation ,myMatch.SubExpressionString(0))
  quit
else
  System.Log(System.LogLevelInformation, "Attempt to get Public failed")
  quit
End if
exception err as RegExException
MsgBox err.message


  Thanks      
_________________
Real Studio 2012 R2
SysInfo
BackTrack Linux/BackBox Linux/Debian Lenny/Windows 7/Windows 8/OpenWRT/OpenBSD  
                             Top                charonn0          Post subject: 
Re: GUI to Console ApplicationPosted: Thu Apr 04, 2013 1:55 pm                  
               
Joined: Mon Apr 02, 2007 2:08 am
Posts: 1179
Location: San Francisco, CA, USA                Copy the code into a console 
application's Run event, change the call to MsgBox into a call to Print then 
and that should be it.      
_________________
Boredom Software  
                             Top                p0wn3d          Post subject: 
Re: GUI to Console ApplicationPosted: Thu Apr 04, 2013 2:08 pm                  
               
Joined: Sun Oct 28, 2012 4:54 am
Posts: 187
Location: Herts, UK               

Wow as simple as that... I like it thanks so much      
_________________
Real Studio 2012 R2
SysInfo
BackTrack Linux/BackBox Linux/Debian Lenny/Windows 7/Windows 8/OpenWRT/OpenBSD  
                             Top             Display posts from previous: All 
posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost 
timeSubject AscendingDescending          Page 1 of 1
   [ 3 posts ]      
-- 
Over 1500 classes with 29000 functions in one REALbasic plug-in collection. 
The Monkeybread Software Realbasic Plugin v9.3. 
http://www.monkeybreadsoftware.de/realbasic/plugins.shtml

[email protected]

Reply via email to