Articles in this section

How to get the name of the file loaded in EditControl?

In Edit control, it is possible to retrieve the file name loaded by using the property, DisplayedFileName. The following code example demonstrates the same.

 

C#

//Gets the name of the file loaded in the EditControl.
String filename = editControl1.DisplayedFileName;

 

VB

'Gets the name of the file loaded in the EditControl.
String filename = Me.EditControl1.DisplayedFileName

 

The following screenshots display the output before and after loading the file in EditControl:

Before loading the file in EditControl

Figure 1: Before loading the file in EditControl

After loading the file in EditControl

Figure 2: After loading the file in EditControl

Sample Links:

C#: EditControl_FileName_C#

VB: EditControl_FileName_VB


Conclusion

I hope you enjoyed learning about how to get the name of the file loaded in EditControl.

You can refer to our  WinForms EditControl feature tour page to know about its other groundbreaking feature representations. You can also explore our WinForms EditControl documentation to understand how to create and manipulate data.

For current customers, you can check out our components from the License and Downloads page. If you are new to Syncfusion, you can try our 30-day free trial to check out our other controls.

If you have any queries or require clarifications, please let us know in the comments section below. You can also contact us through our support forumsDirect-Trac, or feedback portal. We are always happy to assist you!

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Access denied
Access denied