企业绩效管理网

 找回密码
 立即注册

QQ登录

只需一步,快速开始

查看: 713|回复: 6

Run External Application from TM1Web Workbook

[复制链接]

83

主题

392

帖子

567

积分

高级会员

Rank: 4

积分
567
QQ
发表于 2014-3-20 02:45:51 | 显示全部楼层 |阅读模式
Hi gays!
Can anybody help me to resolve next task?
I need to open xls-file from TM1Web WorkSheet by MS Excel as external application.

Thanks for your advice.

yng
回复

使用道具 举报

70

主题

390

帖子

554

积分

高级会员

Rank: 4

积分
554
QQ
发表于 2014-3-20 04:35:18 | 显示全部楼层
What is the location of the Excel file you want to open? Is it on the TM1 Server?

Have you tried using the ExecuteCommand() function? You can use this function within your TI Process to run a desktop application.
回复 支持 反对

使用道具 举报

77

主题

412

帖子

590

积分

高级会员

Rank: 4

积分
590
QQ
发表于 2014-3-20 05:34:03 | 显示全部楼层
@Rizwan have a think about it, ExecuteCommand will run on the TM1 server, the OP is looking for a solution to something in the web client so this clearly isn't going to work.

@yng I don't think this is possible in a one step process as TM1 web is simply built to open excel files as websheets. A 2 step process is possible though: first hyperlink to open as websheet then export to open in excel.
回复 支持 反对

使用道具 举报

71

主题

397

帖子

558

积分

高级会员

Rank: 4

积分
558
QQ
发表于 2014-3-20 05:36:05 | 显示全部楼层
lotsaram wrote:@Rizwan have a think about it, ExecuteCommand will run on the TM1 server, the OP is looking for a solution to something in the web client so this clearly isn't going to work.

Yes, Lotsaram....thats why I asked OP about the location of the file....and I did said that ExecuteCommand will only run the desktop app.
回复 支持 反对

使用道具 举报

75

主题

409

帖子

574

积分

高级会员

Rank: 4

积分
574
QQ
发表于 2014-3-20 06:54:21 | 显示全部楼层
Hi gays!
Can anybody help me to resolve next task?
I need to open xls-file from TM1Web WorkSheet by MS Excel as external application.

Thanks for your advice.

I'm sorry but personally i'd like to be gay the way mrs brady describes it.  
[in brady sequel]

Code: Sub xlObj0(xlCG As Boolean)
   If xlCG Then                                            '} if using existing xl
       xlApp.Visible = True                                '}
       xlApp.EnableEvents = True                           '}
       xlApp.DisplayAlerts = True                          '}
       Else                                                '}
       xlApp.Quit                                          '} quit if new xl created
   End If                                                  '}
   Set xlWkSh = Nothing
   Set xlWkBk = Nothing
   'Set xlApp = Nothing    'this also removes xl !?!
End Sub

Function xlObj1(pxlObj As String, pAlert As Boolean, pVis As Boolean, _
               pEvent As Boolean, Optional pWin As Integer = xlMinimized)
   Dim xlFound As Boolean, gErr As Boolean
   On Local Error GoTo xlERR                               'only sets xlobj
   Select Case pxlObj                                      '} get or create
    Case "c"                                               '}
     xlFound = False
     Set xlApp = CreateObject("excel.application")         '}
    Case "g"                                               '}
     xlFound = True
     Set xlApp = GetObject(, "excel.application")          '}
    Case Else                                              '}
   End Select                                              '}
   xlApp.DisplayAlerts = pAlert                            ' turn off app Dialogs
   xlApp.Visible = pVis                                    '}
   xlApp.EnableEvents = pEvent                             '}
   xlApp.WindowState = pWin
   xlObj1 = xlFound                                        'using existing or new xl
   Exit Function
xlERR:
   Debug.Print Err.Number; Err.Description
   If Err.Number = 429 Then                                '} 429 = ActiveX component can't
     Set xlApp = CreateObject("excel.application")         '} create object
     xlFound = False
   Else
     MsgBox Err.Number & " : " & Err.Description           '} diplay an unknown Error
     gErr = True                                           '} flag error to calling sub
     Exit Function
   End If
   Resume Next
End Function

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?立即注册

x
回复 支持 反对

使用道具 举报

75

主题

385

帖子

554

积分

高级会员

Rank: 4

积分
554
QQ
发表于 2014-3-20 07:22:57 | 显示全部楼层
Thanks all for answers.

I will explain more in detail, what task.

Users work in TM1Web through IE which start on the terminal server. Whether there is a method, from the input form (published WorkSheet) to start on the terminal server in session of the user other xls-file with data TM1, but already in "thick" MS Excel.

On a hyperlink the xls-file opens, but as WorkSheet in TM1Web. It, unfortunately, doesn't approach.

Thanks.
回复 支持 反对

使用道具 举报

80

主题

401

帖子

588

积分

高级会员

Rank: 4

积分
588
QQ
发表于 2014-3-20 07:33:43 | 显示全部楼层
yng wrote:Thanks all for answers.

I will explain more in detail, what task.

Users work in TM1Web through IE which start on the terminal server. Whether there is a method, from the input form (published WorkSheet) to start on the terminal server in session of the user other xls-file with data TM1, but already in "thick" MS Excel.

On a hyperlink the xls-file opens, but as WorkSheet in TM1Web. It, unfortunately, doesn't approach.

Thanks.
As explained TM1 web is doing this because that's what it is designed to do.  You have 2 options, either be happy with a 2 setp process to first open the excel file as a websheet then use the export menu in TM1 web to open the file in Excel.  Or you need to find the follow hyperlink java script function within your TM1 web directory and edit the function.
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|手机版|小黑屋|企业绩效管理网 ( 京ICP备14007298号   

GMT+8, 2023-3-30 20:08 , Processed in 0.069074 second(s), 40 queries .

Powered by Discuz! X3.1 Licensed

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表