UiPath wont recognize textbox and other controls within userform - automation

I have been working on UiPath for quite some time and I have a form where I need to input certain details.
UiPath won't recognize the controls within the form. This form is designed using power builder and the selector looks something as below
<wnd app='pcemain.exe' cls='FNWNS390' title='Open' />
<wnd cls='pbdw90' />

Since the items and their order in the list won't change; you should be able to use the Send Hotkey activity or Type into activity, or a combination of the two.
In some dropdowns, you can type the whole name of the item.
My tip for these kinds of situations, where the (mouse) controls are
challenging, is to try to do the action manually without using the
mouse (or use it as little as possible). When finding a solution, do
it in UiPath

Related

Vba activate grid control as additional control

I want to add control to user GUI that would represent excel like table but I cannot find additional control that would do that. Control like that would be used for easier data entry.
I believe that VBA has control like that and I am missing something obvious.
Does anyone know where to activate control like that?
If you have VB6 installed then, this should work:
Microsoft Flex Grid Control
However, if you do not have (vb6) then, another option is to create one yourself by dynamically adding controls to your UserForm (such as a textbox) and then tracking those object. It would take some work, but it would be an option.

Populate Outlook form Subject from user-defined fields

I designed the form below:
I would like the Subject to be automatically populated with the value of "[Machine] - [TAT]" as soon as those values are filled. I don't know how to access the values of these fields, the syntax for the value change listeners, nor where I should be putting this code.
When I click "Visual Basic", all I see is this:
It seems that this is only programmatic access to the Application, not the form.
How do I programmatically access the form that I designed?
Legacy form customizations require using VBScript for the "code behind", primarily for interactions with your custom UI. However, VBA macros are used independent of custom forms to work with Outlook items and data. If the business logic for your custom form requires working with the active MailItem, then VBScript is what you need to use.
For your scenario, you need to trap changes to the values of your custom controls. The best practice is to create custom fields in the Outlook item and map those fields to the controls. If you don't, you will only be able to write validation formulas in the designer for those controls, and you cannot trap value changes (odd, I know). Luckily custom fields fire the Item_CustomPropertyChange event, which is exactly what you need.
For more info, see:
Manipulating Controls Programmatically
MailItem.CustomPropertyChange Event

Parent form and child User Control communication in WinForms

I have my form with a menu bar and space underneath to display my controls. One of the buttons in my menu bar is suppose to be a print button that prints a graph that's currently in a User Control I display in the form. If the graph was on the form in the print button's eventhandler I could just simply call
graph.printing.print(true)
which isn't going to work in my case since the graph is in the control and not the form.
How do I communicate with a User Control from the containing form and access or pass its variables when needed? I also have a status bar on the bottom of the form which would also need to get updated from the User Control, but I'll be able to deal with that if I got help with just this one part. Please bear in mind, I also have another User Control I'm going to add to the form which will also contain a graph which will need the same treatment as the other graph on the first control when the print button is pressed. I plan on swapping these two out so I have one form displaying one control at a time.
I got this idea from this answer: https://stackoverflow.com/a/18191630/2567273 but after further research I can't find anyone asking about the actual communication process between a form and the control it contains.
I think this answer is close to what I'm looking for, but I think it's leading me down the path to using panels instead of User Controls.
After typing this I noticed the closest answer to my question may be this, but that question has the child raising events and the parent responding while I have the parent raising the event and the parent has to get information from the child.
One way to think about this is Roles. Presumably you built this UserControl to handle the management of the data related to the graphs. As such you can think of them in the Role of a Graphs Specialist . Once you do that, printing them is actually just one more thing it should perhaps do.
The form on the other hand, is not special just because it happens to get receive the command from the user to print. Its role in this might simply to be to know which usercontrol to contact and which method to invoke:
Sub PrintGraphMenuClick....
Select Case something ' determinant as to which UC to contact
Case operation.Foo
ucFoo.PrintGraph
Case operation.Bar
ucBar.PrintGraph
Other menu options like Clear, NewGraph, Save and whatever else there is somewhat the same way. The Form's Role here may be to receive the command from the user and pass it along to the right control, invoking the correct right method and passing the correct parameters - that is not a trivial task.
Of course, rather than a MainMenu, the usercontols could alternatively implement a ContextMenu and even receive those commands directly.
Very often offloading an operation to something else results in so many properties, filenames, streams etc having to be moved from here to there that it becomes burdensome. In this case it is not like the MainForm has some special ability regarding printers that the UserControl cannot handle.
There is only one right solution:
1) Add an event to your user control.
2) Raise the event when the particular "thing" happens in the user control.
3) Attach a handler to the event in Form code.
4) Add code to update the bottom bar in the event handler.

How to set the amount of fields defined by user in VB

How do I set a number in a up/down box then press a button to show me a second form with the amount of fields (like labels with text boxes) defined in the up/down box? I'm new to programming so try to explain in really simple terms if you can. Thanks
Code based solution you can implement now
Container controls in VB.Net inherit usually inherit from Panel control which owns a collection by name Children.
You can add dynamically created controls to this collection to create the second form.
Complex but technically sound solution
Invest sometime to learn XAML and create XAML templates to this job for you. Refer the link here which solves same problem in C#.

Pass hidden data through XUL autocomplete textbox?

One of the controls needed in my xulrunner application is an autocompleting text box which allows the user to type a search term, then looks up completions in an array of objects (each having a generated UUID, canonical name, a list of search terms gleaned from related data, etc.) and allows the user to select just one. Currently I'm using a textbox element of type="autocomplete" and a Javascript custom search component, and it is successfully prefix searching all the search terms and providing completions below the text field, in the customary fashion.
The catch is that I'm not interested in the possibly non-unique label but the object from which the label came, and I can't see any way of passing the object or even any out-of-band UUID back into document land without modifying the XBL or rolling my own control from scratch. Essentially I'm seeking to do what could have been done in HTML with the option[value] attribute. I can't use the built-in type-to-search effect of a standalone menulist because I need to prefix search multiple fields of the object. Any recommendations? Thanks in advance.
I ended up rolling my own as a listbox inside a panel next to a textbox. Even composed into an XBL binding, this was less effort than I'd spent working with the built-in autocomplete textbox and trying to force it to handle what it wasn't intended to handle.