Solved

A question about mirroring that is required for multi-language applications

Posted on 2003-10-21
8
227 Views
Last Modified: 2010-04-17
A question about mirroring that is required for multi-language applications,
where some languages are read from right to left rather than left to right
(Arabic is an example).
How can I reverse the presentation of text strings, or even better, reverse
(or mirror) the entire UI if possible for complete consistency.
My application is written on VB6.

Thanks in advance
0
Comment
Question by:NatalieEng
  • 4
  • 3
8 Comments
 
LVL 41

Expert Comment

by:graye
ID: 9593051
Forms and most ActiveX controls on VB6 support the "RightToLeft" property, which will do what you want.  In VB6 it's called "bi-directional" programming

BTW: VB.Net has much better support for these kinds of globalization features.
0
 

Author Comment

by:NatalieEng
ID: 9597803
Thanks, but if the RightToLeft property of a specific form is set to True, several actions occur:

1. Menus and their associated command names (or items) are right-aligned with RTL reading order. They appear at the right edge of the form in an overall RTL layout.
2. Form captions have an RTL reading order and are right-aligned in the title bar.
3. Any text that the Print method prints to the form will begin at the right boundary of the form and have RTL reading order.
4. Set to true the default RightToLeft property value for newly added controls that have a RightToLeft property.

My problem is what about controls that are already in the form? how can I change their default RightToLeft property value automatically, and not one by one?
0
 
LVL 41

Expert Comment

by:graye
ID: 9598389
Hummm....  I guess you'd just have to run thru the controls collection and set them as you go..

Private Sub Form_Load()
    Dim c As Control
   
    Form1.RightToLeft = True
    For Each c In Form1.Controls
        c.RightToLeft = True
    Next
   
End Sub
0
Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

 

Author Comment

by:NatalieEng
ID: 9599999


_______
|
0
 

Author Comment

by:NatalieEng
ID: 9600347
I want to explain myself better.
I need exactly mirror form of my "Form". For example:

original form:
_________________________________
| __________                                      |
| |TextBox     |            Label                  |
| |_________|                                      |
|________________________________|

Mirror form:

_________________________________
|                                      __________ |
|               Label               |     TextBox| |
|                                      |_________| |
|________________________________|

RightToLeft property cannot do that.
Is there a function or add-in of some sort that can do that? It will really help me!

Thanks in advance.

0
 
LVL 41

Accepted Solution

by:
graye earned 125 total points
ID: 9600638
Oh!

OK... no, there's nothing really that can help with that kind of setup... You could hard-code the upper-lefthand corner locations in an array, and switch the locations in code... but that's pretty hokey.

Once Again, VB.Net can be of tremendous help in this regard, since you can create multiple version of a single GUI based upon Locale and have the correct one display automatically based upon the client's PC settings.
0
 

Author Comment

by:NatalieEng
ID: 9605123
OK

I'll try to find a different way to do it.

Thanks anyway.
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
White board coding practice 3 86
numbers ascending pyramid 101 191
Please explain: Aspect Oriented Programming 2 92
Windows Service to Receive TCP Packets 4 144
Does the idea of dealing with bits scare or confuse you? Does it seem like a waste of time in an age where we all have terabytes of storage? If so, you're missing out on one of the core tools in every professional programmer's toolbox. Learn how to …
Displaying an arrayList in a listView using the default adapter is rarely the best solution. To get full control of your display data, and to be able to refresh it after editing, requires the use of a custom adapter.
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

785 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question