Tutorial - Adobe Flex a partir do zero actualizado. Tutorial - Adobe Flex from scratch updated.


O tutorial que estou a escrever, sofreu algumas alterações, bem como correcções linguísticas e alguns erros detectados foram corrigidos. The tutorial that I write, has suffered some changes and corrections language and some errors were corrected. Apenas actualizei o pdf “Flex Book”. Just upgraded the PDF "Flex Book."

- O index foi alterado, bem com alguns pedaços de código que não estavam devidamente formatados com a sintaxe original do flex (principalmente a parte I). - The index has changed, as well as some pieces of code that were not properly formatted with the syntax of the original flex (especially the part I).

-Foi alterado o tipo de letra para uniformizar o documento, e adicionados alguns pontos novos, tais como a separação por tópicos colocada em relevo, para serem mais faceis de identificar. -It has changed the font to standardize the document, and added some new items, such as the separation of topics raised in relief to be easier to identify.

-Foi adicionada a parte IV do tutorial. -It was added to Part IV of the tutorial.

-Foram adicionados algumas entradas no index que ficam para fazer nas próximas edições -We added some entries in the index that are to do in the next editions

-O número de páginas foi actualizado, contando agora com 46 paginas. -The number of pages has been updated, counting now with 46 pages.

Vou alterar o método de distribuição dos pdf’s na próxima edição, esta e as próximas versões em pdf encontra-se debaixo da licença creative commons: I will change the method of distribution of PDF's next edition, this and future versions can be found in pdf format under the creative commons license:

Atribuição-Uso Não-Comercial-Vedada a Criação de Obras Derivadas 3.0 Unported Attribution-Noncommercial-fenced the creation of Derivative Works 3.0 Unported

Pelo que podem continuar a ler, distribuir, imprimir, etc.. So can continue to read, distribute, print, etc. .. Quase nada mudou (mas leiam os termos no link em cima), apenas é pedido a quem distribuia este “book” que inclua o nome do seu autor (Mário Santos, eu! Almost nothing has changed (but read the words on the link above), who is only asked to distribute this "book" that includes the name of the author (Mario Santos, me! :-) ) bem como o site ( www.msdevtudio.com ), acho que não é pedir muito, ou é? ) And the website (www.msdevtudio.com), I think it is not asking much, is it? :p : p

Creative Commons License Podem ver a versão online disponibilizada nas publicações issuu.com . They can see the online version available in publications issuu.com. (Flash)

Download Flex Book Part 1, 2, 3, 4 Download Flex Book Part 1, 2, 3, 4

Continuo à procura de alguém que esteja interessado em fazer a revisão, apenas que faça uma leitura mais atenta à procura de erros, bem como a testar o código todo descrito neste mesmo tutorial. Still looking for someone who is interested in doing the review, just to make a more careful reading looking for errors and to test all the code described in this same tutorial. A pessoa que proceder a esta revisão será devidamente identificada no tutorial. The person making this revision will be identified in the tutorial. Se alguém estiver interessado informe. Anyone interested please.

Alguma critica, sugestão e/ou comentário será bem vindo. Any criticism, suggestions and / or comments are welcome.

Se alguém estiver interessado em suportar algum do meu trabalho, sinta-se à vontade para fazer uma contribuição, usando o paypal, clicando no botão payPal no topo à direita. Anyone interested in supporting some of my work, feel free to make a contribution, using paypal by clicking on the PayPal button in the top right.
Abraços. Hug.

versão pdf temporariamente indisponivel. pdf version temporarily unavailable.
Deixe um comentário or Deixe um Trackback Leave a comment or Leave a Trackback

21 Comentários 21 Comments

  1. Maio 1, 2008 às 12:26 pm | Permalink May 1, 2008 at 12:26 p.m. pm | Permalink

    Bicho ..maravilhoso seu tutorial ! Man .. its wonderful tutorial! … to fazendo tudo passo a passo e tem algumas coisas na tradução (ou escrita não sei bem se está em PT_BR ou PT) e se for BR posso colaborar revisando mas o meu problema é na execução onde na página 27: ... To doing everything step by step and have some things in translation (or do not know if writing is en or PT) and if BR can collaborate reviewing but my problem is the implementation where on page 27:

    [Bindable]
    public var ……. public var ... ....

    Aparece um warning: A warning appears:
    1084:var’dadosDataGrid’ will be scoped to the default namespace:olaMundo:internal. 1084: var'dadosDataGrid 'will be scoped to the default namespace: olaMundo: internal. It will not be visible outside of this page. It will not be visible outside of this page.

    Não sei o que fiz de errado. I do not know what I did wrong. Estou usando o Adobe Flex buider 3 (não sei se é versão diferente) I'm using Adobe Flex powers conferred 3 (do not know if it is different version)

    Um abraço A hug

  2. Maio 1, 2008 às 3:42 pm | Permalink May 1, 2008 at 3:42 pm | Permalink

    Boas villas.. Good villas ..
    A linguagem é portugues PT, mas se voce seguir o tutorial, e como toda a gente, e for reportando esses possiveis pequenos erros, já ajuda em muito. The language is Portuguese PT, but if you follow the tutorial, and like everyone else, and is reporting these possible small errors, I help much.

    Quanto à sua duvida, voce deve estar a declarar a variavel dentro de uma funçao…verifique se não é isso… As to your question, you must be to declare a variable within a function ... make sure it is not ...

    Tem que ser declarada (variavel global) normalmente no topo do documento! You have to be declared (global variable) usually at the top of the document! a seguir aos imports e fora de qualquer funçao. after the imports and away from any function.

    Seria isso? Would it?

  3. Maio 2, 2008 às 1:14 am | Permalink May 2, 2008 at 1:14 am | Permalink

    Mário já resolvi o ocorrido e confesso que não imagino o que poderia ser, talvez o cache do builder. Mario already decided what happened and I confess that not imagine what could be, perhaps the builder's cache.

    Vou continuar o tutorial. I will continue the tutorial. Com relação a correção da lingua acho pouco prudente pois tem algumas diferenças embora sejam PT hehe ! Regarding the correction of the language think little cautious because it has some differences although PT hehe!

    Grande abraço Big hug

  4. Maio 2, 2008 às 6:06 am | Permalink May 2, 2008 at 6:06 am | Permalink

    Estranho villas, mas normalmente esse erro seria devido à declaração da variavél dentro de uma função… mas como o flex builder às vezes também dispara uns bytes, poderia ser mesmo da cache… rsrsrs Strange villas, but normally this error would be due to the declaration of variable within a function ... but as the flex builder also sometimes shoot each byte, it could be the same cache ... rsrsrs

    Quanto ao tutorial, realmente a nivél de lingua, é um pouco dificil já que as linguas realmente são mesmo um bocado diferentes… mas se encontrar mais algum erro me fala!! As for the tutorial, really the level of language, is a little difficult as the languages are actually even a little bit different ... but if you find a mistake tell me more!

    Assim posso contar com um bocadinho da ajuda de todos So I can count on a little help from everyone :)

    Abraço. Hug.

  5. Maio 2, 2008 às 3:15 pm | Permalink May 2, 2008 at 3:15 pm | Permalink

    Mário acho seria adequado te mandar algumas correções por email. Mario think would be appropriate to send you some fixes via email. Agora estou travado no tutorial talvez seja por uma delas e não consigo fazer o loading sumir após o carregamento(na página 39) Now I'm locked in the tutorial is perhaps one of them and I can not do the loading disappear after loading (on page 39)

    1046: Type was not found or was not a compile-time constant: ModuleEvent. 1046: Type was not found or was not a compile-time constant: ModuleEvent. olaMundo mainScript.as line 96 olaMundo mainScript.as line 96

  6. Maio 2, 2008 às 3:25 pm | Permalink May 2, 2008 at 3:25 pm | Permalink

    Opa .. Oops .. revisei o código e consegui. the code and checked it. Sumiu o erro. Gone the error. Eu simplesmente apaguei a function e reescrevi dando espaço e aguardando a sugestão do builder que não tinha aparecid anteriormente. I just blacked out the function and rewrites giving space and awaiting the suggestion that the builder had not previously aparecid.
    Então pode ter sido erro na digitação pois não estou fazendo copy/paste para aprender. So it could have been error in typing because I am not doing copy / paste to learn.

    Um abraço e fico no aguardo do teu email A hug and I look forward in your email

    o meu é villas2terra.com.br mine is villas2terra.com.br

  7. Maio 2, 2008 às 5:26 pm | Permalink May 2, 2008 at 5:26 pm | Permalink

    Enviei um email para voce agora… I sent an email to you now ...

    As vezes esses erros podem acontecer mesmo por distração… ainda bem que solucionou. Sometimes these mistakes can happen even by distraction ... even though it solved.

    Faz muito bem não fazer copy/paste, já que assim aprende mesmo!! Do not do very well copy / paste, as well learn it! :)

    Um abraço. A hug.

  8. Maio 3, 2008 às 1:03 am | Permalink May 3, 2008 at 1:03 am | Permalink

    Mário não recebi o email Mario did not get the email

    tenta o edu(arroba)villasweb.com por favor que pelo terra não veio. edu try the (snail) villasweb.com please that the land did not come.

  9. Maio 3, 2008 às 1:28 am | Permalink May 3, 2008 at 1:28 am | Permalink

    Mário só agora que eu li direito e vi o: Mario only now that I looked right and saw:
    Boas Villas … e achei interessante pois meu nome é Villas Boas hehehe .. Villas Boas ... and I found interesting because my name is Villas Boas hehehe ..

    bom sobre o tutorial empaquei na página 41 e não consigo descobrir o erro que aparece no flex: good tutorial on the packages on page 41 and can not discover the error that appears in flex:

    1195: Attempted access of inaccessible method defineUser through a reference with static type modLogin. 1195: Attempted access of inaccessible method defineUser through a reference with static type modLogin. olaMundo mainScript.as line 104 olaMundo mainScript.as line 104

    Não consigo descobrir o que fiz de errado. I can not figure out what I did wrong. será que você por acaso desconfia? will be by chance that you distrust?

    Abraço Hug

    Eduardo Villas Boas Eduardo Villas Boas

  10. Maio 3, 2008 às 1:51 am | Permalink May 3, 2008 at 1:51 am | Permalink

    Detalhes sobre o erro: Details about the error:
    O botão Define User não aparece na renderização The User Set button does not appear in rendering

  11. Maio 3, 2008 às 6:30 am | Permalink May 3, 2008 at 6:30 am | Permalink

    Villas, me mostra a sua linha 104. Villas, shows me his line 104. E entretanto verifique se tem a função defineUser bem feita no modLogin.. And now verify that the function defineUser has done well in modLogin ..

    Esse erro está a dizer que é impossivél aceder ao método defineUser()… This error is saying that it is impossible to access the method defineUser () ...

  12. Maio 3, 2008 às 12:39 pm | Permalink May 3, 2008 at 12:39 pm | Permalink

    nao sei se vai aparecer o código I do not know whether the code will appear

    no arquivo mainScript.as in the mainScript.as

    private function define():void{ private function define (): void (
    if((loader.getChildren()).length>0) if ((loader.getChildren ()). length> 0)
    (loader.child as modLogin). (loader.child the modLogin).
    inputUser(”TESTANDO”); inputUser ( "test");
    else Alert.show(”Modulo ainda Não carregado”); Alert.show else ( "Module not yet loaded");
    } )

    No modLogin.mxml In modLogin.mxml

  13. Maio 3, 2008 às 1:46 pm | Permalink May 3, 2008 at 1:46 pm | Permalink

    Bom, já recebi o seu email e vi que ficou resolvido esse problema, que pelo que parece talvez fosse por ter o inputUser(”TESTANDO”); na linha de baixo. Well, I got your email and saw that it was resolved that problem, and it seems that it might be for the inputUser ( "test"); line at the bottom. deve estar tudo na mesma linha: everything must be on the same line:

    (loader.child as modLogin).inputUser(”TESTANDO”); (loader.child the modLogin). inputUser ( "test");

    :)

  14. Maio 3, 2008 às 9:35 pm | Permalink May 3, 2008 at 9:35 pm | Permalink

    Mário terminei o tutorial as mil maravilhas. Mario finished the tutorial swimmingly. Agora refazer tudo do zero do zero e adequar as minhas aplicações principalmente a comunicação com o php. Now redo everything from scratch from scratch and tailor my applications mainly the communication with the php.

    Que tal na parte 5 uma grid com inserir, editar, deletar etc ?? How about in part 5 with a grid insert, edit, delete, etc?

    Parabéns Congratulations

  15. Maio 4, 2008 às 10:36 am | Permalink May 4, 2008 at 10:36 a.m. am | Permalink

    Ainda bem Eduardo. Glad Eduardo.

    Quanto à parte 5 ainda está no forno… ando sem muito tempo.. As for part 5 is still in the oven ... without walking a long time .. mas vamos a ver se lá para o meio do mês estará terminada… but we are going to see if there in the middle of the month will be completed ...

    Quanto ao datagrid, existe aqui no blog um exemplo que pode dar uma olhada: As for the datagrid, there is the example that a blog can take a look:
    http://msdevstudio.com/blog/2008/03/25/flex-datagrid-operaes-no-dataprovider/ http://msdevstudio.com/blog/2008/03/25/flex-datagrid-operaes-no-dataprovider/

    Utiliza um dataprovider criado na aplicação, mas já pode ver como funciona as operações CRUD nos dataProviders. Uses a DataProvider created in the application, but can already see how the CRUD operations in dataProviders. :)

    Abraço e obrigado pelos “erros” detectados! Hug and thanks for the "errors" detected!

  16. Julho 16, 2008 às 6:53 pm | Permalink July 16, 2008 at 6:53 pm | Permalink

    Fiquei com uma dúvida aqui olhando o book online. I have a question here looking at the book online.
    Exemplo: Example:

    Por que as vezes um objeto do tipo Panel é instanciado Why are the times an object of type Panel is instantiated
    com parenteses e as vezes sem parenteses: with parentheses and the times without parentheses:
    var painel2:Panel = new Panel(); var painel2: Panel = new Panel ();
    var novo:Panel = new Panel; var new: Panel = new Panel;

    Há alguma diferença? Is there any difference?

    Encontrei também no book online alguns erros de português. I found the book online also some errors in Portuguese.

  17. Julho 16, 2008 às 8:12 pm | Permalink July 16, 2008 at 8:12 pm | Permalink

    Na realidade essas declarações funcionam praticamente da mesma maneira, declaram uma nova instancia do painel. In fact these statements work virtually the same way, declare a new instance of the panel. O que significa que na pratica resulta na mesma coisa, têm como por exemplo usar ou não usar o ponto-e-virgula ; no final de cada linha, se usar funciona, se não usar, funciona na mesma… This means that in practice results in the same thing, are such as to use or not use a semicolon; at the end of each line, using works, if you do not use, works on the same ...

    Quanto aos erros de português, penso que teria corrigido praticamente todos, mas caso tenha encontrado algum informe. The errors of Portuguese, I think we would have corrected almost everyone, but if you have found any report.

    ps Note que é Português de Portugal ps Note that it is Portuguese in Portugal :)

    Um abraço. A hug.

  18. renan Renan
    Setembro 20, 2008 às 11:27 pm | Permalink September 20, 2008 at 11:27 a.m. pm | Permalink

    Tranquei na sessão 7.4, em dois momentos, no primeiro, envolvendo as páginas 38-39, no trecho: Locked in the session 7.4, at two points in the first, involving the pages 38-39, in part:

    private function carregaModulo():void{ carregaModulo private function (): void (
    loader.url=”modLogin.swf”; loader.url = "modLogin.swf";
    loader.loadModule(); loader.loadModule ();
    loaderBar.source=loader; loaderBar.source = loader;
    } )

    Cita o erro “1020: access of undefined property loader.” nas três linhas de ‘loader’, e outro específico para a linha com o ‘loaderBar’. It cites the error "1020: access of undefined property loader." In three lines of 'loader', and another specific to the line with the 'loaderBar'.

    Sem achar o erro (e inclusive usando copiar/colar para ver se eu achava onde errei, caso fosse digitação), tentei ignorar, e seguindo com os exemplos, de acordo com as páginas 39-40: Without find the error (and even using copy / paste to see if I thought which missed, if typing), I tried to ignore and along with the examples, according to pages 39-40:

    O erro das três linhas some com o acréscimo da função seguinte, mas então nesta função surge o erro “1046: Type was not found or was not a compile-time constant: ModuleEvent.”, resource “mainScript.as”, path “olaMundo/src”, eo erro é citado duas vezes, referindo a linha “private function loadTerminado(event:ModuleEvent):void {”. The error of three lines with the addition of some light ahead, but then this function is the error "1046: Type was not found or was not a compile-time constant: ModuleEvent." Resource "mainScript.as," path "olaMundo / src ", and the error is cited twice, the row referindo" private function loadTerminado (event: ModuleEvent): void ( ".

    (a ProgressBar não some; o botão “Define User” não aparece) (a ProgressBar not some, the "User defined" does not appear)

    Tive esperança de entender pelo problema que talvez fosse o mesmo do Villas, mas passei a tarde inteira passando a limpo (e inclusive copiando e colando) sem entender onde é que eu estou errando. I hope to understand the problem that it might be the same as the Villas, but spent the entire afternoon going to clean (and even copying and pasting) does not understand where I'm missing.

    Uma luz? A light?

    Obrigado. Thank you.

    PS Na primeira versão do capítulo 4, havia dois pontos de referência sobre popUpManager.createPopUp, que nunca foram citados antes, então eu subentendi que era uma confusão com o “centerPopUp” da página anterior. PS In the first version of Chapter 4, had two points of reference on popUpManager.createPopUp, which have never been cited before, so I understood it was a confusion with the "centerPopUp" of the previous page. Funcionou. It worked. Na revisão, de fato, o primeiro foi substituído por “centerPopUp”, ao invés de “createPopUp”, mas o segundo (na parte inferior da página), permanece como “create”, ao invés de “center”. In the review, in fact, the first was replaced by "centerPopUp" rather than "createPopUp", but the second (bottom of page), remains as "create" instead of "center".

  19. Setembro 21, 2008 às 10:05 am | Permalink September 21, 2008 at 10:05 a.m. am | Permalink

    Bom dia Renan. Morning Renan.

    Dá erro nesse loader, eo erro indica que não é possivel aceder ao loader, ou seja, o loader ou não têm o id=”loader” ou o loader não foi iniciado (sinal que podes ter a função colocada no ficheiro errado…) Give this loader error, and error indicates that it is not possible to access the loader, that is, the loader or do not have the id = "loader" or the loader was not started (signal that can be placed depending on the file wrong ...)

    o erro do module event dá-se porque copiaste o código do book… the error in the event module because there is copy the code book ...

    mete junto dos imports: stick with the imports:

    import mx.events.ModuleEvent; mx.events.ModuleEvent import;

    e deve resolver. and must resolve.

    Não copies o código, faz sempre de novo, porque existem certos imports que são inseridos automaticamente ao escrever e não aparecem se copiares… Do not copy the code, is always new, because there are certain imports that are automatically inserted to write and do not appear if you copy ...

    se não conseguires resolver coloca uma duvida com o código todo em http://forum.msdevstudio.com assim lá é mais facil de eu ver o código e de tirar a duvida. If you can not resolve raises a doubt with the code at all http://forum.msdevstudio.com so there is easier that I see the code and to take the doubt.

    Abraço. Hug.

  20. Cristiano Cristiano
    Setembro 21, 2008 às 8:02 pm | Permalink September 21, 2008 at 8:02 pm | Permalink

    Eu ainda não li por completo este tutorial, mas olhando por cima já gostei muito. I have not read in full this tutorial, but looking over already liked a lot. Parabéns pela vontade de ensinar Congratulations on the desire to teach :)

  21. Setembro 23, 2008 às 7:36 pm | Permalink September 23, 2008 at 7:36 pm | Permalink

    Obrigado Cristiano… quando terminar fala o que achou e deixe a sua opinião, critica ou sugestão! Thanks Cristiano ... when you finish that thought the speech and let your opinion, suggestion or criticism!

    Abraço. Hug.

4 Trackbacks 4 Trackbacks

  1. [...] Entradas » Ultimos Comentários » Entradas Populares » » Tutorial - Adobe Flex a partir do zero actualizado. [...] Entries' Latest Comments' Popular Entries' `Tutorial - Adobe Flex from scratch updated. » Top 10 erros ao desenvolver aplicações Flex. "Top 10 mistakes when developing Flex applications. » Adobe video workshop - [...] "Adobe video workshop - [...]

  2. [...] Entradas » Ultimos Comentários » Entradas Populares » » Tutorial - Adobe Flex a partir do zero actualizado. [...] Entries' Latest Comments' Popular Entries' `Tutorial - Adobe Flex from scratch updated. » Top 10 erros ao desenvolver aplicações Flex. "Top 10 mistakes when developing Flex applications. » Adobe video workshop - [...] "Adobe video workshop - [...]

  3. [...] Entradas » Ultimos Comentários » Entradas Populares » » Tutorial - Adobe Flex a partir do zero actualizado. [...] Entries' Latest Comments' Popular Entries' `Tutorial - Adobe Flex from scratch updated. » Top 10 erros ao desenvolver aplicações Flex. "Top 10 mistakes when developing Flex applications. » Adobe video workshop - [...] "Adobe video workshop - [...]

  4. [...] Adobe  Flex Buider a partir do zero - parte 1, 2, 3, 4. [...] Adobe Flex allocated from scratch - Part 1, 2, 3, 4. Até a Próx.dica. Until the Próx.dica. Gostou do da Post?Vote nele: These icons link to social bookmarking sites where readers can share and discover new web pages. Like that of the Post? Vote on it: These icons link to social bookmarking sites where readers can share and discover new web pages. [...]

Deixe um comentário Leave a comment

O seu email nunca será publicado ou partilhado. Your email is never published or shared. Campos obrigatórios estão marcados com um * Required fields are marked with an *

*
*




"));