Jump to content

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Find out more here. X
X


Photo

CustomBox (udf) (updated, new: ability to change buttons)


  • Please log in to reply
17 replies to this topic

#1 ludocus

ludocus

    Possibly inventive crap going on right here

  • Active Members
  • PipPipPipPipPipPip
  • 668 posts

Posted 04 October 2008 - 07:35 PM

I made this custom msgbox!
Pictures, Source, Example, Readme and old pictures:
Attached File  CustomBox.zip   10.08KB   485 downloads
previous downloads: 35

Source alone:
Attached File  CustomBox.au3   14.73KB   359 downloads
Previous downloads: 5

Check out the new possibility of choosing options!
I Changed the pictures.. looks different (maybe worse :P )
I added new function: _CustomInputBox!!!
Now its possible to change the button names

the options work the same as with normal msgbox:
CODE

Return Value - Button Pressed:
1 = OK
2 = Cancel
4 = RETRY
5 = IGNORE
6 = YES
7 = NO
10 = TRY AGAIN
11 = CONTINUE

Opts - Result:
0 = OK button
1 = OK and Cancel
2 = Abort, Retry, and Ignore
3 = Yes, No, and Cancel
4 = Yes and No
5 = Retry and Cance
6 = Cancel, Try Again, Continue


Enjoy:)

Edited by ludocus, 05 October 2008 - 03:25 PM.








#2 TehWhale

TehWhale

    Whalee..

  • Banned (NOT IN USE)
  • 1,482 posts

Posted 04 October 2008 - 07:39 PM

I made this custom msgbox!
Source:


example:

#include <CustomBox.au3> $msgbox = _CustomBox('Hello', 'Hello Ladies and gentlemen!', -1, -1, 0) if $msgbox = 1 then     _CustomBox('Notification', 'You Clicked Ok') Else     _CustomBox('Notification', 'You Clicked Close') EndIf exit


You need the following pictures (in your temp directory):
Titlebar.bmp
Button.bmp
Leave.bmp

Enjoy:)

Why don't you take the pictures, read them to binary, and have your script write them in the temp directory?

#3 Andreik

Andreik

    Bishop

  • Active Members
  • PipPipPipPipPipPip
  • 2,565 posts

Posted 04 October 2008 - 07:40 PM

Just tried your example but disappear very fast the message box.
When the words fail... music speaks

#4 ludocus

ludocus

    Possibly inventive crap going on right here

  • Active Members
  • PipPipPipPipPipPip
  • 668 posts

Posted 04 October 2008 - 07:47 PM

@Andreik: then you dont have the images in temp dir..
@SwiftBurns: Dude, I wanted to do that for a long time.. But I got no clue how?? please tell me..

Edited by ludocus, 04 October 2008 - 07:47 PM.


#5 gseller

gseller

    Universalist

  • Active Members
  • PipPipPipPipPipPip
  • 1,057 posts

Posted 04 October 2008 - 08:08 PM

Very Nice!! I like it!

#6 Andreik

Andreik

    Bishop

  • Active Members
  • PipPipPipPipPipPip
  • 2,565 posts

Posted 04 October 2008 - 08:08 PM

@Andreik: then you dont have the images in temp dir..
@SwiftBurns: Dude, I wanted to do that for a long time.. But I got no clue how?? please tell me..

Yeah, looks good but use FileInstall or other methods to put files in TempDir.
When the words fail... music speaks

#7 ludocus

ludocus

    Possibly inventive crap going on right here

  • Active Members
  • PipPipPipPipPipPip
  • 668 posts

Posted 04 October 2008 - 08:08 PM

thnx :P

/edit
I did that andreik..

Edited by ludocus, 04 October 2008 - 08:14 PM.


#8 TehWhale

TehWhale

    Whalee..

  • Banned (NOT IN USE)
  • 1,482 posts

Posted 04 October 2008 - 08:45 PM

@OP to include them in binary, use FileOpen() With the Binary type, and then use FileRead, and then later use FileWrite(2+Binarymode) :P

#9 ludocus

ludocus

    Possibly inventive crap going on right here

  • Active Members
  • PipPipPipPipPipPip
  • 668 posts

Posted 04 October 2008 - 10:01 PM

New update!!... all options of a normal msgbox (flags)..
@Swift: Dude I did this.. and it works (thnx!!!) but the lines I get are too big.. scite becomes really, really, really slow.. (like 1 min per character I type)..
and when I press F5 (run) it errors: Unable to Parse Line.. so then I put these things: ' before and after the line..
and then it errors something about... I forgot.. Well it errors..
so this doen't work :P..
But still, Thnx!

#10 TehWhale

TehWhale

    Whalee..

  • Banned (NOT IN USE)
  • 1,482 posts

Posted 04 October 2008 - 10:43 PM

New update!!... all options of a normal msgbox (flags)..
@Swift: Dude I did this.. and it works (thnx!!!) but the lines I get are too big.. scite becomes really, really, really slow.. (like 1 min per character I type)..
and when I press F5 (run) it errors: Unable to Parse Line.. so then I put these things: ' before and after the line..
and then it errors something about... I forgot.. Well it errors..
so this doen't work :(..
But still, Thnx!

Use

$BinaryCode = "0xf44asf4f64f54f4f564a56sf456a4sf5f45f0f000f0f0f0f0f0f0f0f0f0f0ff0f0f0f0f0f0f0f0f0f0f0f0f0"& _
"4f5s4df56f0f0f0f0f0f0f0f0ff0f0f0f0f0f0f0f0f0f00000000000000000000000000000000000000000000000000

00"& _
....Like so :P

#11 ludocus

ludocus

    Possibly inventive crap going on right here

  • Active Members
  • PipPipPipPipPipPip
  • 668 posts

Posted 05 October 2008 - 09:23 AM

Updated the pictures!!!
@Swift: That will take ages.. cause the line I get returned is extremely long..
maybe ill make something that will do that automatic..

/edit:
@Swift (again): I tried that with this:
#Include <File.au3> $p = FileOpen('leave.bmp', 16) $txt = FileRead($p) FileClose($p) $length = StringLen($txt) $ret = @Tab&'$leave = ' msgbox(0, $length, $length/20) For $i = 20 to $length step 20     $left = StringLeft($txt, 20)     $ret &= '"'&$left&'"& _'&@CRLF&@TAB     $txt = StringReplace($txt, $left, '') Next ClipPut($ret)

1: for some reason it adds much to much lines.. but if I get rid of them its ok..
2: when I create it for the code, and then open the file with Windows image Viewer it sais: unable to build up image..

Edited by ludocus, 05 October 2008 - 09:57 AM.


#12 Zedna

Zedna

    AutoIt rulez!

  • MVPs
  • 8,557 posts

Posted 05 October 2008 - 12:26 PM

@ludocus: Take a look at my Resources UDF http://www.autoitscript.com/forum/index.php?showtopic=51103

#13 ludocus

ludocus

    Possibly inventive crap going on right here

  • Active Members
  • PipPipPipPipPipPip
  • 668 posts

Posted 05 October 2008 - 01:44 PM

updated it!: I added new function: _CustomInputBox!!!
@Zedna: wow that is way to complicated for me :P

#14 ProgAndy

ProgAndy

    You need AutoItObject

  • MVPs
  • 2,508 posts

Posted 05 October 2008 - 02:06 PM

Here i posted a script to make the AutoIt HEX source out of a file
*GERMAN* Posted Image [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes

#15 ludocus

ludocus

    Possibly inventive crap going on right here

  • Active Members
  • PipPipPipPipPipPip
  • 668 posts

Posted 05 October 2008 - 02:47 PM

thnx.. tried it, and it worked!
but: the titlebar.bmp is too big for a var.. it sais something bla bla.. overflow..
so I just am not going to do this anymore!

Edited by ludocus, 05 October 2008 - 02:48 PM.


#16 ludocus

ludocus

    Possibly inventive crap going on right here

  • Active Members
  • PipPipPipPipPipPip
  • 668 posts

Posted 05 October 2008 - 03:25 PM

new update:
Now its possible to change the button names

#17 JavaScript_Freek

JavaScript_Freek

    Oldie but never advanced.

  • Active Members
  • PipPipPipPipPipPip
  • 318 posts

Posted 03 February 2009 - 10:26 PM

Ok. I got CustomBox.au3 in /Includes/ but when I press Server than Client.. the cleint.au3 flashes for like a second. :)

#18 ludocus

ludocus

    Possibly inventive crap going on right here

  • Active Members
  • PipPipPipPipPipPip
  • 668 posts

Posted 25 June 2009 - 07:00 PM

uhh.. Why are you talking about that in this topic?




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users