OpenOffice.org Forum at OOoForum.orgThe OpenOffice.org Forum
 
 [Home]   [FAQ]   [Search]   [Memberlist]   [Usergroups]   [Register
 [Profile]   [Log in to check your private messages]   [Log in

[SOLVED] First post: I need some help getting started

 
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Macros and API
View previous topic :: View next topic  
Author Message
meldawn
Newbie
Newbie


Joined: 19 Sep 2008
Posts: 2

PostPosted: Fri Sep 19, 2008 3:12 pm    Post subject: [SOLVED] First post: I need some help getting started Reply with quote

I have been cruising the internet for any script that will allow a beginner, to base and macros, get any kind of an idea where to start. I could not find one. I did find a bunch of "I would not suggest" comments.
That said, I have one "simple" question to ask that, I hope, will give my intellectual ball rolling.

I have a form. Let's call it [Form1]. On that form I have a button, call it [Button1]. I also have a text box, call it [George]... I hate to be completely predictable.

Now, I want to click [Button1] and have [George] say Hello World!.

Can someone help me get started here? Seems like a simple little macro to write. Please correct me if i am totally false in this assumption.
_________________
Meldawn


Last edited by meldawn on Mon Sep 22, 2008 10:10 am; edited 2 times in total
Back to top
View user's profile Send private message
SilverCapo
OOo Enthusiast
OOo Enthusiast


Joined: 22 May 2006
Posts: 102
Location: UK

PostPosted: Fri Sep 19, 2008 4:35 pm    Post subject: Reply with quote

OK some good places to start:

Andrew's Macro Examples - downloadable from:
http://www.pitonyak.org/oo.php

OOo Basic tutorial and intro:
http://wiki.services.openoffice.org/wiki/Documentation/BASIC_Guide

The tutorial is quite an easy read and should get you started - and the 1000s+ examples in Andrew's document should give you an idea in doing just about anything you can think of using OOo Basic macros

The X-ray tool is also a must-have for getting around the API
http://wiki.services.openoffice.org/wiki/Extensions_development_basic#X-Ray_tool
Back to top
View user's profile Send private message
QuazzieEvil
Super User
Super User


Joined: 17 Jan 2007
Posts: 599
Location: Houston, TX

PostPosted: Sat Sep 20, 2008 5:08 pm    Post subject: Reply with quote

you can also take a look at my free docs at www.geocities.com/rbenitez22
_________________
Free Docs @ http://www.baseprogramming.com/resources.html
Book @ lulu.com http://www.lulu.com/content/2455551
Back to top
View user's profile Send private message Visit poster's website
JohnV
Administrator
Administrator


Joined: 07 Mar 2003
Posts: 9183
Location: Lexinton, Kentucky, USA

PostPosted: Sun Sep 21, 2008 9:06 am    Post subject: Reply with quote

Specifically for Base try the free download of Mark B's chapter 6.
http://www.packtpub.com/files/Learn-OpenOffice-Working-with-Databases-Sample-Chapter.pdf
Back to top
View user's profile Send private message
meldawn
Newbie
Newbie


Joined: 19 Sep 2008
Posts: 2

PostPosted: Mon Sep 22, 2008 10:36 am    Post subject: Reply with quote

All of you rock! I used QuazzieEvil's FormsAndDialogs pdf to figure this out. http://www.geocities.com/rbenitez22/OOo/FormsAndDialogs.pdf

Here is answer to my question. I hope this helps to get more people started.

Code:

Sub Main (Event As Object)

'xray thisComponent

Dim Form As Object
Dim george As Object

Form=Event.Source.Model.Parent

george=Form.GetByName("george")
george.Text="hello world"


End Sub


Thank you all!!
_________________
Meldawn
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Macros and API All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group