Modify TEXTBOX (I can't think of a good title)

My program creates a TEXTBOX with a message in it(it says TYPE HERE). What I would like to have happen is the message will disappear when someone starts typing in the box. Right now the existing message scrolls to the right as characters are typed.
I can seems to find this solution. I'm thinking it might be possible to do this by GraphicsWindow.hide()/GraphicsWindow.show(), but can't seem to get it right.
This is my very first question, so if I am breaking some rules I apologize. Thank you.
My code follows (it has some extra stuff not actually involved in the program, because I copied this code from someone else. Whose name I forgot, sorry)
'Initialize a user friendly window
GraphicsWindow.BackgroundColor = "Cyan" 'An 'easy on the eyes' color
GraphicsWindow.Height = 230 'Make it 230 pixels tall
GraphicsWindow.Width = 600 'and 600 pixels wide
GraphicsWindow.BrushColor = "Black" 'Make all text black
GraphicsWindow.FontSize = 20 '
textbox = Controls.addtextbox(10,50)
Controls.SetTextBoxText(textbox "Type Here")
Controls.SetSize(textbox,580,40) 'Set it to be 20 pixels less then the width of the window
btnCheck = Controls.AddButton("Test Program",110,100) 'Add a button for checking the input
txtOutput = Shapes.AddText("mytest") 'Add some output text to change later
Shapes.Move(txtOutput,10,150) 'Move it below the button
Controls.ButtonClicked = ButtonClick
Sub ButtonClick
EndSub

Without extension i don't know an other way, but with LitDev extension you can do almost everything, except flying:
tb = Controls.AddTextBox(10,10)
Controls.SetTextBoxText(tb, "Type Here")
LDShapes.SetShapeEvent(tb)
LDShapes.ShapeEvent = OnShapeEvent
Sub OnShapeEvent
' "MouseDown" ShapeEvent is NOT working for TB !
'If LDShapes.LastEventShape = tb And LDShapes.LastEventType = "MouseEnter" Then
If LDShapes.LastEventType = "GotFocus" And cleared <> "True" Then ' or "MouseEnter"
Controls.SetTextBoxText(tb, "")
cleared = "True"
EndIf
EndSub
Or
initText = "Type Here"
tb = Controls.AddTextBox(10,10)
btn = Controls.AddButton("Demo", 10,50)
Controls.SetTextBoxText(tb, initText)
LDShapes.SetShapeEvent(tb)
LDShapes.ShapeEvent = OnShapeEvent
Sub OnShapeEvent
If LDShapes.LastEventType = "GotFocus" And Controls.GetTextBoxText(tb) = initText Then
Controls.SetTextBoxText(tb, "")
ElseIf LDShapes.LastEventType = "LostFocus" And Controls.GetTextBoxText(tb) = "" Then
Controls.SetTextBoxText(tb, initText)
EndIf
EndSub
Look at IntelliSense help in LitDev Extension for
LDShapes...  .SetShapeEvent, .ShapeEvent, .LastEventShape, .LastEventType

Similar Messages

  • 2 Questions (I can't think of a good subject)

    1) you can put 2 strings together using the + operator , is it possible (if so how) can i make it for my own objects do that , such that i can write my own addition or somthing method , and i'm trying to avoid somthing like obj1.add(obj2) , i would prefer , obj1+obj2
    2) in an abstract class , i can setup methods to be in any class that extends it, is there a way to setup constructors?

    1) you can put 2 strings together using the +
    operator , is it possible (if so how) can i make it
    for my own objects do that , such that i can write my
    own addition or somthing method , and i'm trying to
    avoid somthing like obj1.add(obj2) , i would prefer ,
    obj1+obj2No. Java does not have operator overloading.
    >
    2) in an abstract class , i can setup methods to be
    in any class that extends it, is there a way to setup
    constructors?You mean abstract constructors? No. Constructors are not inherited and cannot be abstract.

  • TS2446 I just got my iPad,  I have an iPod. When I go to put apps on it says my apple I'd Is disabled. I have reset the passwords. Somehow I have two id's?  I've gone into settings for apps signed out and back in with the new p.w.  I can't think of what e

    I just got my iPad,  I have an iPod. When I go to put apps on my new ipad it says my apple ID Is disabled. I have reset the passwords. Somehow I have two id's?  I've gone into settings for apps signed out and back in with the new p.w.  I can't think of what else to do to get the disabled block off.  Any ideas?? Thanks

    See this Apple document for help...
    http://support.apple.com/kb/ts2446

  • I have a Power PC G4 which is running on OSX 10.5.8, it has the AirPort utility but cannot connect to the internet as my iMac can, I think I might need an AirPort Card? Is that the case or do I need something different to connect to a wireless modem?

    I have a Power PC G4 which is running on OSX 10.5.8, it has the AirPort utility but cannot connect to the internet as my iMac can, I think I might need an AirPort Card? Is that the case or do I need something different to connect to a wireless modem?

    Welcome!
    Only one variant of the PowerMac G4 could use the faster Airport Extreme Card. The rest used the original Airport card that is pretty slow.
    To get fast wireless without buying more than one thing, consider this:
    http://eshop.macsales.com/item/Edimax/EW7722IN/
    It goes in an available PCI slot
    There are USB solutions also. However, all PowerMac G4 towers had only slower USB 1.1 ports, so any USB wireless adaptor can only run at about wireless 'B" speeds (slow) unless you also install a PCI USB 2.0 adaptor card. Doing that would allow a USB wireless adaptor to run at its maximum rated speed. These items working together would accomplish that:
    USB wireless "dongle:"
    Newer Technology MAXPower 802.11n/g/b USB Adapter + Plug and play direct or with extension cradle
    USB PCI adaptor:
    http://eshop.macsales.com/Search/Search.cfm?Ntk=Primary&Ns=P_Popularity%7c1&Ne=5 000&N=7069&Ntt=USB+PCI
    Each approach has its advantages. The PCI wireless card is a one-piece solution that takes up no desk space. The USB2 card+USB2 Dongle gives you more fast ports for transferring date from other external USB devices (primarily cameras and external hard drives) at hugely faster rates than can the original ports. I have a USB 2 PCI card in my G4 tower strictly for transferring images from my digital SLR camera in a timely manner.

  • Ned to back up files.  Trying to reformat a WD 1TB external hard drive but my utilities keeps saying "choose scheme from volume pop up menu.." also says cannot be modified.  What can I do?!

    Help would be appreciated! Before I upgrade my 10.6.8 OS X I need to back up files.  Trying to reformat a WD 1TB external hard drive but my utilities keeps saying "choose scheme from volume pop up menu.." also says "this partition cannot be modified."  What can I do?! Take it back to Currys!  Many thanks

    Select the Top Most Entry for that drive, it will be the drive model # and have the size listed, then go to the Partition tab and select One Partition from the Partition Layout area drop down. Then select Mac OS Extended (Journaled) as the format, if that is the format you want to format it AS. Then click the Options button near the bottom of that windows and select GUID as the Partition Table. Close the options screen and clcik the Apply button.

  • Can U Think of Any Situation Where U Find VENDOR Info. Populated for a STO?

    Hi,
    Can you think of any situation where you will find VENDOR information populated for a STO moving stock from a Plant to Store under the same company code?
    I got an error ("Enter goods for vendor XXXX only") and this was triggered by the fact that one STO had vendor information in the delivery document. The outcome of this was that every STO beneath this STO could not be GR, but every STO before and including the STO were GR without any issues....
    Your response is higly appreciated..
    Thanks

    SegeTx,
    I am not sure exactly what you mean when you say "Vendor information populated for an STO".  Is this a UB STO?
    Tell me exactly what transaction you are performing, and the data you are entering, when you get the GR error.
    Generally, when you set up master data for a STO, you have to assign a vendor to the plant. It is possible that somehow the source plant has become un-assigned from the vendor.   WB03, clik past any warnings, enter the plant.  In the upper right corner, there should be a vendor.  If nothing is there, then you have to re-assign the vendor to the source plant.  MK02 enter the vendor you wish to assign to the plant, and the purch org you should use for the STOs.  Execute.  Select  extras > addl purch data.  enter the plant.  Save.
    Best Regards,
    DB49

  • Okay. when i connected my iphone 5 to itunes it replaced all of the data from my old iphone 3gs (contacts, apps, notes, bookmarks,photos, music, everything you can possibly think of) with my new iphone 5's data. I am so frustrated with this. Why?

    okay. when i connected my iphone 5 to itunes it replaced all of the data from my old iphone 3gs (contacts, apps, notes, bookmarks,photos, music, everything you can possibly think of) with my new iphone 5's data. I am so frustrated with this. Why? and it did it by itself, i didnt touch anything, or clicked anything. please help me this is urgent! I am a businessman and need my contacts.

    You're iPhone was probably set to automatically sync with your iTunes upon plugging it in. Best option is to restore from a backup, either on iCloud or your computer.

  • Moving button links - can't think how

    Hey All
    I have a site i am putting together, and my list of buttons
    is sitting at the bottom of my site - i want it to be at the top of
    the content image, and below the logo. But its not..... and i can't
    think why?
    I attached the html and the code.
    Thanks!

    Post a link to the page please. The code you show below is
    not so
    informative.
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    http://www.projectseven.com/go
    - DW FAQs, Tutorials & Resources
    http://www.dwfaq.com - DW FAQs,
    Tutorials & Resources
    ==================
    "thewakeplace.com" <[email protected]> wrote
    in message
    news:[email protected]...
    > Hey All
    >
    > I have a site i am putting together, and my list of
    buttons is sitting
    > at
    > the bottom of my site - i want it to be at the top of
    the content image,
    > and
    > below the logo. But its not..... and i can't think why?
    >
    > I attached the html and the code.
    >
    > Thanks!
    >
    > <body>
    > <div id="container">
    > <div id="content">
    > <h1><a href="/">Monkey Bean
    Media</a></h1>
    > <ul class="navigation">
    > <li><a href="/">Home</a></li>
    > <li><a
    href="/">Portfolio</a></li>
    > <li><a href="/">Reel</a></li>
    > <li><a href="/">Gear</a></li>
    > <li><a href="/">Contact</a></li>
    > </ul>
    > </div>
    > <div id="footer">
    > </div>
    > </div>
    > </body>
    > </html>
    >
    >
    >
    >
    >
    >
    > CSS -
    >
    >
    > body, div, h1, h2, h3, h4, p, ul, ol, li, dl, dt, dd,
    img, form, field {
    > margin: 0px;
    > padding: 0px;
    > border: 0px;
    > }
    >
    > body {
    > background: #000 url(images/background.jpg) top center
    no-repeat;
    > font: 12px Arial, Helvetica, sans-serif;
    > }
    >
    > ul.navigation {
    > width: 600px; height: 25px; float: left; text-align:
    center;
    >
    > }
    >
    > ul.navigation li {
    > display: inline-block;
    > margin-left: 10px; padding: 15px 20px;
    > }
    >
    > ul.navigation li a:link, ul.navigation li a:visited {
    > font: 14px Arial, Helvetica, sans-serif;
    > text-decoration: none;
    > color: #FFFFFF;
    > }
    >
    > ul.navigation li a:hover, ul.navigation li a:active {
    > color: #b6dce5;
    > }
    >
    > html { height: 100%; margin-bottom: 1px;
    > }
    >
    > #container {
    > width: 1000px;
    > margin: 0 auto;
    > background: url(images/content_strip.jpg) repeat-y;
    > }
    >
    > #content {
    > background: url(images/content_top.jpg) top no-repeat;
    margin-top: 258px;
    > min-height: 500px;
    > }
    >
    > #footer {
    > height: 41px;
    > background: url(images/footer.jpg);
    > }
    >
    > h1 a {
    > display: block; width: 401px; height: 200px;
    margin-left: 300px;
    > margin-bottom: 300px;
    > text-indent: -9999px;
    > }
    >

  • I can't understand how to edit titles on the spine of books. Could anyone help me? Thanks.

    I can't understand how to edit titles on the spine of books. Could anyone help me? Thanks.

    the trouble is that on the spine of the book the title is cut off and I don't know how avoid it.
    I don't think you can, Fred. Pick a shorter title. And add the additional information by adding a subtitle on your title page. You can always add a second text box, using the "edit layout" panel.
    Regards
    Léonie

  • I just burned photos from different albums to CD-R. When I checked on the photos I burned on the CD-R afterwards,  I noticed that the titles of each folder that these photos are extracted from appear. How can I get rid of these titles???

    I just burned photos from different albums to CD-R. When I checked on the photos I burned on the CD-R afterwards,  I noticed that the titles of each folder that these photos are extracted from appear. How can I get rid of these titles???

    iPhoto 9.6 cannot open iPhoto Libraries on CD/DVD. The iPhoto Library needs to be on a writable storage.  Copy the iPhoto library from the disk to a folder in your Pictures folder. And then run the iPhoto Library Upgrader on that copy, see this link:  iPhoto '11: About the Library Upgrader

  • Book: can I sort the photos by title not by date

    Creating a book in iPhoto is now much cumbersome.  In the past, I could arrange the photos in an album and when I created the book from the album, the photos were sorted according to their order in the album.  Now, the photos are sorted by date.  How can I change the sort to 'title' and not 'date' in the list of photos in the book?
    Lance

    You can't - you can select the photos in the album and use the batch change date time command wth a small increment to make the time sequence match your order
    LN

  • HT204406 How can I browse directly by song title?

    How can I browse directly by song title? Can't seem to do it on the new version.

    Hello Dick
    When you are looking at your music, there should be some tabs towards the top. It will let you change the organization and the view types. The article below will give you some useful features that you can use.
    iTunes 11: Frequently used features
    http://support.apple.com/kb/HT5649
    Thanks for using Apple Support Communities.
    Regards,
    -Norm G.

  • How can I import pics with the title info?

    How can I import pics with the title info? Title info not importing, just the pics with original title info

    jfromcal wrote:
    the info is on the pics on the cd I'm importing to my iphoto library. I maybe using the wrong terminology. Basically naming or writing a description underneath for each individual photo.
    js
    exactly where is it - the file name? in the IPTC data? Actually "on the photo"?
    LN

  • How can I un-receive an good receipt in SAP, FOR A CERTAIN LINE ITEM

    hi experts,
    can any one please help me to solve this issue.
    "How can I un-receive an good receipt in SAP, FOR A CERTAIN LINE ITEM"
    thanks in advance,
    mohammad.

    Hi,
    In T-code MIGO, you select the line item you want and enter all the details of this line in Item details. Tick Item Ok indicator for this line item.
    Untill and unless you tick the item ok indicator for certain line item you couldnot receive the material.
    If you already received the material then Go to MBST and cancel the material document for the same.
    Hope this will help you.
    Regards,
    Goraksh.
    Edited by: goraksh dhikale on Sep 22, 2008 11:30 AM

  • Why i can not see the Document goods movements from T-CODE  CO03 ?

    Hello,
        why i can not see the Document goods movements list use T-CODE CO03 ?  I'm sure i have issueed for this production order. thanks.
    xinzhou.

    Hi,
    Is this a problem with only one order? or with all the Orders of the same "Order Type".
    If this is with only one Order, check goods movements actually done or not?
    If this problem is with other Orders as well (same Order Type), then with the T.Code; OPL8.
    In the 2nd Tab Page (Implemenation) - Whether the Check boxes are filled for Documented Goods Movements??
    Regards,
    Siva

Maybe you are looking for

  • Not able to ADD video presets to Photoshop CC

    Hi there I am currently using Photoshop to edit videos but the render settings that I need are not available in the Export menu. With Adobe Media Encoder I have saved off the preset I need and added it to the following folders: C:\Programmes\Adobe\Ad

  • Why is the strain on my laptop so much larger using CS6

    Hello I have a HP Laptop i7 with an upgrade to 16GB of Ram.   The CPU always ran between 5 and   10 percent The Ram upgrad made CS 5.5  preview window go back in sync. Hooray! But since I liked CS 5.5 I thought why not go to CS6. Now my CPU hits 100

  • Recovery Strategy - Need Some Information - Critical

    Hello all, I need help from you all to understand the following scenario: 1.We have a Production database which is running in ARCHIEVELOG mode. 2.This database is supported with FAILOVER Machenism. 3.The backup strategy is as follows 3.1 Sunday Level

  • Data Template---master details query--Help

    Hi we are using XML Publisher attached to R12 , we are using data template ( .XML file) in data definition . we have a requirement for master details report. for that we have parent query and child query .the data coming to parent query should be the

  • IDOC segment attributes confusion....

    Hi ABAP Gurus, I have doubt realted to IDOCS. I was looking at the attributes of one of the IDOC segment. There are three things: 1) Mandatory Flag, 2) Minimum Number,3) Maximum Number Now in this particular segment I found: Mandatory Flag: Not set M