The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum for Programming
 LabTalk Forum
 UIM button bug
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

lunchpack

Germany
20 Posts

Posted - 01/26/2015 :  10:50:27 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Ver.9.0Pro and Service Release (Select Help-->About Origin): 9.0 Pro SR2
Operating System: Win8 x64

Hi all,
i found a weird bug when using UIM control buttons.
Try this: Have a new graph window or a new layout window and create a UIM button which executes "win -d;" (duplicate) on button up. The window gets duplicated, but in the duplicated window the button does not work anymore (not even the button down animation). This does NOT happen when you do the same thing in a new worksheet.

What's the difference? And how can I duplicate a graph using a script linked to a button in that graph?

Thanks a lot!
Cheers, lunchpack

Edited by - lunchpack on 01/27/2015 12:02:37 AM

JacquelineHe

287 Posts

Posted - 01/27/2015 :  05:34:01 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi,

Thanks for reporting this problem to us.

Currently we can't fix the problem immediately, but we will submit a task and sent to our developer.

If you don't mind, could you please send your project file to us?
Tech Support department: tech@originlab.com
Please mention this forum post in the Email.

Additional, our developer hopes to know why you need this kind of script. That is easy to lead infinite loop.


Thanks
Jacqueline
OriginLab
Go to Top of Page

lunchpack

Germany
20 Posts

Posted - 01/27/2015 :  07:57:24 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi Jacqueline,

thanks for your reply. I've submitted a project file for illustration and a bug description by email.

Cheers,
Christian
Go to Top of Page

minimax

348 Posts

Posted - 01/28/2015 :  03:24:41 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi lunchpack,

We can see the problem with your project.

However, we still wonder why you would like to adding such a script on a window.

On Origin's toolbar, there is a duplicate toolbar, which can do a same operation as yours.

Is there any typical reason on using the UIM button instead?

Max
OriginLab
Go to Top of Page

lunchpack

Germany
20 Posts

Posted - 01/28/2015 :  05:47:51 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi Max,

thanks for the information.

I'm well aware of the toolbar duplicate button. But I'm trying to develop a simple GUI for data analysis which I'd like to share with other scientists. I also had a look into the ODK, but VC++ and the ODK seem like an absolute overkill for what this script actually needs to do. The plan was to put the GUI into an empty graph window, save it as *.ogg and then anyone can add it to an existing project.

In these projects, this graph window containing the GUI needs to be copied to each subfolder where data is imported. And that's what the button is supposed to do. Choosing files (dlgfile), Importing files (using impexcel), organize the imported data into subfolders and then put a copy of the GUI graph window in each of these folders. Of course this can be done by hand, but I don't want to bother other users doing something manually.

I could ofcourse just run the script that includes that duplication command from a custom toolbar rather than from an UIM button (in fact, that's what I am used to call scripts from). But when it comes to sharing scripts with Labtalk/Origin C inexperienced users it is much more trouble setting up a custom menu rather than opening a *.ogg file and clicking a button.

I hope I could shed some light on my problem ;-)

Thanks for the effort anyways!

Cheers,
Christian
Go to Top of Page

minimax

348 Posts

Posted - 01/30/2015 :  01:55:38 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi lunchpack,

You may try following script to make it work on Graph window:

;{win -d;}

where ; is used to delay its execution, see more reference on
http://www.originlab.com/doc/LabTalk/guide/Using-Semicolons-in-LT


Go to Top of Page

lunchpack

Germany
20 Posts

Posted - 01/30/2015 :  03:29:17 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Amazing! Works like a charm, thank you so much! I never quite understood when exactly Origin needs to relax for a moment (e.g. it needs to take a break after plotting using plotxy and applying a theme using applytheme2g - without a break the second x-function just gets skipped...). But for the button, it actually does make sense...

Great, problem solved! Have a great weekend!
Go to Top of Page

AnnaSharpe

USA
1 Posts

Posted - 02/11/2015 :  12:30:23 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thanks for the information.

Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000