x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

How to add button in to vertical box dynamically?

Hi, guys.

This pictures are my game screenshot.

alt text

Each pawns has their own widget object, and each widget has different information.

One of them, each widget has a different kinds and different number of skill text and buttons.

How to add button into vertical box in constructor?

Product Version: UE 4.18
Tags:
more ▼

asked Nov 19 '17 at 05:12 AM in Blueprint Scripting

avatar image

RedChiken
32 4 5 9

(comments are locked)
10|2000 characters needed characters left

2 answers: sort voted first

alt text

1.jpg (145.0 kB)
more ▼

answered Nov 19 '17 at 05:52 AM

avatar image

Zedokus
33 6 7

avatar image Everynone Nov 19 '17 at 12:01 PM

This is the way to go. I'll just add that you can run it in a loop and expose variables on spawn. This will allow you to customise the newly spawned widgets.

avatar image RedChiken Nov 19 '17 at 03:29 PM

I'm sorry. I think I didn't write enough about my problems. My widget have some empty vertical boxes. And I want to add some text or buttons and click on event of that buttons when i spawn widget during game. I tried upside way, but widget cannot cast to button or text box. It couldn't work when I use editable text box or text block too.

My question is, "How to add text box or button as a child of vertical box dynamically"

(comments are locked)
10|2000 characters needed characters left

alt text

maybe you mean this :) UMG default widget are not UserWidget, and they have to be constructed as all other objects :P

immagine.png (51.0 kB)
more ▼

answered Nov 17 '18 at 10:23 PM

avatar image

loris.demarchi
1 2

(comments are locked)
10|2000 characters needed characters left
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question