Done using below code.
Code:
Dim VisualRelation, RelationToTextBox, TextBoxDesc
Set VisualRelation = VisualRelations.Create
Set RelationToTextBox = VisualRelation.Add
RelationToTextBox.relatedobjectpath = "JavaWindow(""title:=Main"").JavaStaticText(""label:=Box1"")"
RelationToTextBox.relativeposition = micRelLeft
RelationToTextBox.setargument micRelInline, True
Set TextBoxDesc = Description.Create
TextBoxDesc("Class Name").Value = "JavaEdit"
TextBoxDesc("visual relations").Value = VisualRelation
JavaWindow("title:=Main").JavaEdit(TextBoxDesc).Type "val"