SysDictEnum InventTransPostingTypeEnum = new SysDictEnum(enumnum(InventTransPostingType) );
InventTransPostingTypeEnum.value2Label(_SID.InventTransPostingType);
Kamis, 22 Desember 2016
Rabu, 21 Desember 2016
AX : Working with dates X++ (https://dynamicsaxed.wordpress.com/2015/06/04/working-with-dates-in-x/)
I was working on some date related functionality the other day during
which I discovered some really useful date functions in X++. Some of
you might be familiar with some of this already, however it is always
good to have a blog post out there that lists them all for future
reference. I have also added sample code for the usage of each function.
Initialization
A date variable can be initialized with a date constant. The date literal in X++ has a predefined format i.e. dd\MM\yyyy. Note that backslash is used instead of forward slash and unlike string constants neither single nor double quotes is used.
transDate = 01\01\2015;
today
Returns the date of the machine on which the code is run.
transDate = today();
systemDateGet
Selasa, 20 Desember 2016
AX : Pengurangan Bulan dari 2 Variabel
bulan=intvNo(paramFromDate, paramToDate, intvScale::YearMonth);
AX: Get End Month AX 2012
you can get end month with endmth
example
endmth(dateMthFwd(tanggalmulai,-jmlbulan));
example
endmth(dateMthFwd(tanggalmulai,-jmlbulan));
Rabu, 14 Desember 2016
Query : Contoh Query Fcuntion SQL Server
create function CustBalanceAsOfTransDatex ( @AsOfDate datetime, @DataAreaID varchar(10) )
returns table
as return (
select a.ACCOUNTNUM, sum(AMOUNTMST - isnull(Terbayar, 0)) as Sisa, cust.CUSTGROUP,dirp.NAME as names
from (
select
ct.*,
(select sum(SETTLEAMOUNTMST - EXCHADJUSTMENT)
from CUSTSETTLEMENT cset
where cset.ACCOUNTNUM = ct.ACCOUNTNUM and cset.TRANSRECID = ct.RECID
and partition = 5637144576 and DATAAREAID = @DataAreaID
and cset.TRANSDATE <= @AsOfDate)
as Terbayar
from
(
select VOUCHER, INVOICE, CLOSED, POSTINGPROFILE, AMOUNTMST, AMOUNTCUR, RECID, ACCOUNTNUM, TRANSDATE
from CUSTTRANS
where --AccountNum = 'CUST-C006' and
partition = 5637144576 and DATAAREAID = @DataAreaID
and TRANSDATE <= @AsOfDate
and TransType in (
0, --None
2, -- Sales
15, -- payment
8, -- cust
36 -- General Journal
) and
POSTINGPROFILE = 'GEN' and (Closed = '1900-01-01' or Closed > @AsOfDate)
) ct
) a inner join CUSTTABLE cust on a.ACCOUNTNUM = cust.ACCOUNTNUM
inner join DIRPARTYTABLE dirp on cust.PARTY = dirp.RECID
where a.AMOUNTMST - isnull(a.Terbayar, 0) <> 0
group by a.ACCOUNTNUM, cust.CUSTGROUP,dirp.NAME
)
go
returns table
as return (
select a.ACCOUNTNUM, sum(AMOUNTMST - isnull(Terbayar, 0)) as Sisa, cust.CUSTGROUP,dirp.NAME as names
from (
select
ct.*,
(select sum(SETTLEAMOUNTMST - EXCHADJUSTMENT)
from CUSTSETTLEMENT cset
where cset.ACCOUNTNUM = ct.ACCOUNTNUM and cset.TRANSRECID = ct.RECID
and partition = 5637144576 and DATAAREAID = @DataAreaID
and cset.TRANSDATE <= @AsOfDate)
as Terbayar
from
(
select VOUCHER, INVOICE, CLOSED, POSTINGPROFILE, AMOUNTMST, AMOUNTCUR, RECID, ACCOUNTNUM, TRANSDATE
from CUSTTRANS
where --AccountNum = 'CUST-C006' and
partition = 5637144576 and DATAAREAID = @DataAreaID
and TRANSDATE <= @AsOfDate
and TransType in (
0, --None
2, -- Sales
15, -- payment
8, -- cust
36 -- General Journal
) and
POSTINGPROFILE = 'GEN' and (Closed = '1900-01-01' or Closed > @AsOfDate)
) ct
) a inner join CUSTTABLE cust on a.ACCOUNTNUM = cust.ACCOUNTNUM
inner join DIRPARTYTABLE dirp on cust.PARTY = dirp.RECID
where a.AMOUNTMST - isnull(a.Terbayar, 0) <> 0
group by a.ACCOUNTNUM, cust.CUSTGROUP,dirp.NAME
)
go
Jumat, 25 November 2016
Register all .dll in one folder
you can use this :
for %A in (*.dll) do regsvr32 /u /s %A && regsvr32 /s %A
Kamis, 17 November 2016
Query Join AX 2012 Version 2
public void executeQuery()
{
QueryBuildDataSource cpj;
QueryBuildDataSource bol;
query query;
query = CustPackingSlipJour_ds.query();
cpj = query.dataSourceTable(tableNum(CustPackingSlipJour));
bol = cpj.addDataSource(tableNum(WMSBillOfLadingOrder));
bol.joinMoIde(JoinMode::ExistsJoin);
bol.fetchMode(QueryFetchMode::One2One);
bol.relations(false);
bol.addLink(fieldNum(CustPackingSlipJour, SalesId), fieldNum(WMSBillOfLading, InventTransRefId));
super();
}
I tried the same in a job and it worked:
static void Job21(Args _args)
{
Query query;
QueryRun queryrun;
QueryBuildDataSource cpj;
QueryBuildDataSource bol;
QueryBuildRange qbr1;
CustPackingSlipJour custPackingslipJour;
WMSBillOfLadingOrder wmsBillOfLadingOrder;
;
query = new query();
cpj = query.addDataSource(tablenum(CustPackingSlipJour));
qbr1 = cpj.addRange(fieldnum(CustPackingSlipJour,orderAccount));
qbr1.value(queryvalue('CUST001'));
bol = cpj.addDataSource(tablenum(WMSBillOfLadingOrder));
bol.relations(false);
bol.joinMode(joinmode::InnerJoin);
bol.addLink(fieldnum(CustPackingSlipJour,SalesId),fieldnum(WMSBillOfLadingOrder,InventTransRefId));
queryrun = new queryrun(query);
while(queryrun.next())
{
custPackingslipJour = queryrun.get(tablenum(CustPackingSlipJour));
wmsBillOfLadingOrder = queryrun.get(tablenum(WMSBillOfLadingOrder));
info(strfmt("%1 - %2",custPackingslipJour.salesid, wmsBillOfLadingOrder.billOfLadingId));
}
}
{
QueryBuildDataSource cpj;
QueryBuildDataSource bol;
query query;
query = CustPackingSlipJour_ds.query();
cpj = query.dataSourceTable(tableNum(CustPackingSlipJour));
bol = cpj.addDataSource(tableNum(WMSBillOfLadingOrder));
bol.joinMoIde(JoinMode::ExistsJoin);
bol.fetchMode(QueryFetchMode::One2One);
bol.relations(false);
bol.addLink(fieldNum(CustPackingSlipJour, SalesId), fieldNum(WMSBillOfLading, InventTransRefId));
super();
}
I tried the same in a job and it worked:
static void Job21(Args _args)
{
Query query;
QueryRun queryrun;
QueryBuildDataSource cpj;
QueryBuildDataSource bol;
QueryBuildRange qbr1;
CustPackingSlipJour custPackingslipJour;
WMSBillOfLadingOrder wmsBillOfLadingOrder;
;
query = new query();
cpj = query.addDataSource(tablenum(CustPackingSlipJour));
qbr1 = cpj.addRange(fieldnum(CustPackingSlipJour,orderAccount));
qbr1.value(queryvalue('CUST001'));
bol = cpj.addDataSource(tablenum(WMSBillOfLadingOrder));
bol.relations(false);
bol.joinMode(joinmode::InnerJoin);
bol.addLink(fieldnum(CustPackingSlipJour,SalesId),fieldnum(WMSBillOfLadingOrder,InventTransRefId));
queryrun = new queryrun(query);
while(queryrun.next())
{
custPackingslipJour = queryrun.get(tablenum(CustPackingSlipJour));
wmsBillOfLadingOrder = queryrun.get(tablenum(WMSBillOfLadingOrder));
info(strfmt("%1 - %2",custPackingslipJour.salesid, wmsBillOfLadingOrder.billOfLadingId));
}
}
Senin, 07 November 2016
AX : Disabled Enabled Button AX 2012 ( Simple Case )
Dalam hal ini saya mempunya form Down Payment..di tabel purchdp_header( custom table), nah saya ingin ketika nomor_dp itu ditemukan di table LedgerJournalTrans maka tombol edit di Form Down Payment menjadi disabled..sebelumnya saya memakai Class Interaction namun saya mencoba cara sederhana dengan menggunakan Class Active di datasource PurchDP-Header di form tersebut..isi class Activenya sebagai berikut :
public int active()
{
int ret;
AmountCurDebit nilaisum;
PurchDP_Header pdph;
LedgerJournalTrans ljth;
//info(PurchDP_Header.Nomor_PurchDP);
ret = super();
select * from ljth where ljth.Nomor_DP==PurchDP_Header.Nomor_PurchDP;
//nomordp=ljth.AmountCurDebit;
nilaisum=ljth.AmountCurDebit+ljth.AmountCurCredit;
// info(int2str(amcd));
if(nilaisum> 0)
{
buttonEditDP.enabled(false);
}
else
{
buttonEditDP.enabled(true);
}
return ret;
}
public int active()
{
int ret;
AmountCurDebit nilaisum;
PurchDP_Header pdph;
LedgerJournalTrans ljth;
//info(PurchDP_Header.Nomor_PurchDP);
ret = super();
select * from ljth where ljth.Nomor_DP==PurchDP_Header.Nomor_PurchDP;
//nomordp=ljth.AmountCurDebit;
nilaisum=ljth.AmountCurDebit+ljth.AmountCurCredit;
// info(int2str(amcd));
if(nilaisum> 0)
{
buttonEditDP.enabled(false);
}
else
{
buttonEditDP.enabled(true);
}
return ret;
}
Kamis, 20 Oktober 2016
JEASYUI : Chained Combobox JEASYUI ( combo box bertingkat )
View Utama
<div class="fitem">
<label>Provinsi:</label>
<select class="easyui-combobox" name="provinsi" id="provinsi" required="true" >
<option value="<?php echo isset($_POST['provinsi']) ? $_POST['provinsi'] : ''; ?>"></option>
<?
foreach ($provins as $provinss) {
?>
<option value="<?= $provinss['IDProvinsi']; ?>"><?= $provinss['NamaProvinsi']; ?>
</option>
<?php
}
?>
</select>
</div>
<div class="fitem" name="kotalook">
<label>Kota:</label>
<label id="kotalook"> </label>
</div>
<div class="fitem">
<label>Provinsi:</label>
<select class="easyui-combobox" name="provinsi" id="provinsi" required="true" >
<option value="<?php echo isset($_POST['provinsi']) ? $_POST['provinsi'] : ''; ?>"></option>
<?
foreach ($provins as $provinss) {
?>
<option value="<?= $provinss['IDProvinsi']; ?>"><?= $provinss['NamaProvinsi']; ?>
</option>
<?php
}
?>
</select>
</div>
<div class="fitem" name="kotalook">
<label>Kota:</label>
<label id="kotalook"> </label>
</div>
Minggu, 02 Oktober 2016
IT : ODBC Driver tidak dapat view semua driver database
This problem can occur because of a architecture problem (32-bit office running on 64-bit windows) or a permissions problem.
The following steps can be used to solve this problem:
1. Navigate to "C:\Windows\SysWOW64"
2. Find "odbcad32.exe", right click on it and do "Run As Administrator"
3. Then continue following the steps listed in the Database Toolbox Guide.
After following the above steps, you will be able to see all the data sources.
The following steps can be used to solve this problem:
1. Navigate to "C:\Windows\SysWOW64"
2. Find "odbcad32.exe", right click on it and do "Run As Administrator"
3. Then continue following the steps listed in the Database Toolbox Guide.
After following the above steps, you will be able to see all the data sources.
Minggu, 18 September 2016
AX : Cara Mendapatkan Datetime berjalan
untuk mendapatkan data dengan format datetime yang sedang berjalan adalah dengan menggunakan :
DateTimeUtil::utcNow();
DateTimeUtil::utcNow();
AX : Cara mendapatkan user yang sedang aktif
untuk mendapatkan user yang sedang aktif adalah dengan menggunakan :
curUserId();
curUserId();
Kamis, 04 Agustus 2016
XAMPP: mengganti port apache xampp
Untuk mengubah port default apache, kita harus mengedit file konfigurasi apache, yakni file httpd.conf.
Untungnya, di XAMPP Control panel telah disediakan shortcut file
setingan ini. Apabila web server apache sedang berjalan, silahkan
matikan terlebih dahulu.
Klik tombol config pada bagian actions XAMPP, dari menu yang tersedia, klik Apache (httpd.conf). Akan tampil file konfigurasi apache di Notepad. Kita tinggal mengubah beberapa pengaturan.
Dalam contoh kali ini saya akan mengubah port apache dari 80 menjadi 8080. Namun pada prakteknya kita bebas ingin menggunakan port apa saja, (selama tidak bentrok dengan aplikasi lain). Anda bisa mengubahnya menjadi 81, 8888, atau 999.
Pada file httpd.conf yang telah terbuka, Cari baris “Listen 80”, kemudian ubah angka 80 ini menjadi port baru, misalnya menjadi “Listen 8080“.
Masih di file yang sama, cari baris “ServerName localhost:80” kemudian ubah menjadi “ServerNamelocalhost:8080“. Simpan pengaturan, dan tutup file ini.
Langkah selanjutnya adalah mengubah pengaturan port SSL apache, dimana defaultnya menggunakan port 443. Caranya hampir mirip. Kembali klik tombol config pada bagian actions XAMPP, dari menu yang tersedia, kali ini klik Apache (httpd-ssl.conf). File tersebut akan kembali terbuka di notepad.
Carilah baris “Listen 443” dan ubah menjadi “Listen 4433”. Sama seperti port yang lain, kita bisa menggunakan port apa saja. Nomor 4433 yang saya pilih hanya salah satu contoh saja.
Masih di file yang sama, cari baris “virtualhost_default_:443” kemudian ubah menjadi “virtualhost_default_:4433“, dan terakhir cari baris “ServerName localhost:443” dan ubah menjadi “ServerName localhost:4433“. Simpan pengaturan dan tutup file ini. Perubahan port Apache sudah selesai!
Untuk memastikan, silahkan jalankan web server apache menggunakan XAMPP Control Panel. Jika pada bagian port sudah berubah menjadi 8080 dan 4433 dan tidak ada error berarti kita telah sukses mengubah port apache.
Klik tombol config pada bagian actions XAMPP, dari menu yang tersedia, klik Apache (httpd.conf). Akan tampil file konfigurasi apache di Notepad. Kita tinggal mengubah beberapa pengaturan.
Dalam contoh kali ini saya akan mengubah port apache dari 80 menjadi 8080. Namun pada prakteknya kita bebas ingin menggunakan port apa saja, (selama tidak bentrok dengan aplikasi lain). Anda bisa mengubahnya menjadi 81, 8888, atau 999.
Pada file httpd.conf yang telah terbuka, Cari baris “Listen 80”, kemudian ubah angka 80 ini menjadi port baru, misalnya menjadi “Listen 8080“.
Masih di file yang sama, cari baris “ServerName localhost:80” kemudian ubah menjadi “ServerNamelocalhost:8080“. Simpan pengaturan, dan tutup file ini.
Untuk mencari baris perintah ini akan lebih mudah jika kita menggunakan fitur find di notepad (CRTL + F), kemudian tinggal ketik angka port seperti 80 atau 443.
Carilah baris “Listen 443” dan ubah menjadi “Listen 4433”. Sama seperti port yang lain, kita bisa menggunakan port apa saja. Nomor 4433 yang saya pilih hanya salah satu contoh saja.
Masih di file yang sama, cari baris “virtualhost_default_:443” kemudian ubah menjadi “virtualhost_default_:4433“, dan terakhir cari baris “ServerName localhost:443” dan ubah menjadi “ServerName localhost:4433“. Simpan pengaturan dan tutup file ini. Perubahan port Apache sudah selesai!
File settingan apache ini sebenarnya bisa diakses secara manual pada folder instalasi_xampp\apache\conf. Jika XAMPP diinstall di C:\xampp, maka lokasi foldernya akan berada di C:\xampp\apache\conf.
SQL Server : Import Database SQL Server
1. Siapkan terlebih dahulu database yang akan di import, biasanya sih
berupa .bak, dalam hal ini database yang hendak saya import namanya
adalah shopGratis seperti gambar di bawah ini:
AX ; X++ Count Query
CONTOH :
static void Query_cntRecords(Args _args)
{
Query query = new Query();
QueryRun queryRun;
QueryBuildDataSource qbd;
;
qbd = query.addDataSource(tablenum(CustTable));
queryRun = new QueryRun(query);
info(strfmt("Total Records in Query %1",SysQuery::countTotal(queryRun)));
}
static void Query_cntRecords(Args _args)
{
Query query = new Query();
QueryRun queryRun;
QueryBuildDataSource qbd;
;
qbd = query.addDataSource(tablenum(CustTable));
queryRun = new QueryRun(query);
info(strfmt("Total Records in Query %1",SysQuery::countTotal(queryRun)));
}
IT : Cara Instal SQL Server 2016 ( )
coba buka di website berikut
http://www.sqlcoffee.com/sqlserver2014_0005.htm
http://www.sqlcoffee.com/sqlserver2014_0005.htm
Query : Contoh Query Trigger ( II )
Tahap berikutnya adalah membuat trigger yang akan melakukan populasi
data yang dihapus dari "tr_penjualan" ke table "tr_penjualan_hapus".
Berikut adalah perintahnya :
Berikut adalah perintahnya :
DELIMITER |
CREATE TRIGGER hapus_tr_penjualan AFTER DELETE
ON tr_penjualan FOR EACH ROW
BEGIN
INSERT INTO tr_penjualan_hapus
( tgl_transaksi,
kode_cabang,
kode_kasir,
kode_item,
kode_produk,
jumlah_pembelian,
tgl_perubahan,
nama_user
)
VALUES
( OLD.tgl_transaksi,
OLD.kode_cabang,
OLD.kode_kasir,
OLD.kode_item,
OLD.kode_produk,
OLD.jumlah_pembelian,
SYSDATE(),
CURRENT_USER
);
END;
|
CREATE TRIGGER hapus_tr_penjualan AFTER DELETE
ON tr_penjualan FOR EACH ROW
BEGIN
INSERT INTO tr_penjualan_hapus
( tgl_transaksi,
kode_cabang,
kode_kasir,
kode_item,
kode_produk,
jumlah_pembelian,
tgl_perubahan,
nama_user
)
VALUES
( OLD.tgl_transaksi,
OLD.kode_cabang,
OLD.kode_kasir,
OLD.kode_item,
OLD.kode_produk,
OLD.jumlah_pembelian,
SYSDATE(),
CURRENT_USER
);
END;
|
DELIMITER ;
Query : Contoh Query Trigger
ALTER trigger [dbo].[tr_LedgerJournalTrans_InsUpdDel] on [dbo].[LEDGERJOURNALTRANS]
for insert, update, delete
as
begin
set nocount on
update pd
set pd.SISADP = isnull(
(select sum((AMOUNTCURDEBIT - AMOUNTCURCREDIT))
from LedgerJournalTrans ljt
where pd.NOMOR_PURCHDP = ljt.NOMOR_DP and pd.DATAAREAID = ljt.DATAAREAID and pd.PARTITION = ljt.PARTITION), 0)
from PURCHDP_HEADER pd
where exists (
select 1
from deleted d
where isnull(d.NOMOR_DP, '') <> '' and pd.NOMOR_PURCHDP = d.NOMOR_DP and pd.DATAAREAID = d.DATAAREAID and pd.PARTITION = d.PARTITION
)
or
exists (
select 1
from inserted i
where isnull(i.NOMOR_DP, '') <> '' and pd.NOMOR_PURCHDP = i.NOMOR_DP and pd.DATAAREAID = i.DATAAREAID and pd.PARTITION = i.PARTITION
)
set nocount off
end
for insert, update, delete
as
begin
set nocount on
update pd
set pd.SISADP = isnull(
(select sum((AMOUNTCURDEBIT - AMOUNTCURCREDIT))
from LedgerJournalTrans ljt
where pd.NOMOR_PURCHDP = ljt.NOMOR_DP and pd.DATAAREAID = ljt.DATAAREAID and pd.PARTITION = ljt.PARTITION), 0)
from PURCHDP_HEADER pd
where exists (
select 1
from deleted d
where isnull(d.NOMOR_DP, '') <> '' and pd.NOMOR_PURCHDP = d.NOMOR_DP and pd.DATAAREAID = d.DATAAREAID and pd.PARTITION = d.PARTITION
)
or
exists (
select 1
from inserted i
where isnull(i.NOMOR_DP, '') <> '' and pd.NOMOR_PURCHDP = i.NOMOR_DP and pd.DATAAREAID = i.DATAAREAID and pd.PARTITION = i.PARTITION
)
set nocount off
end
Rabu, 03 Agustus 2016
IT : Mengatasi TeamViewer Expired
Mengatasi Team Viewer Expired
1> Pertama Uninstall Team Viewer , Add or remove‘ dapat di temukan di: ‘Start’ –> ‘Settings’ –> ‘Control Panel’.
2> Click on Start –> Run –> ketik %appdata% –> delete TeamViewer folder juga hapus “C:\\Program Files\\Teamviewer”.
3> Hapus registry folder: Start –> Run –> ketik regedit masuk ke hkcu/software/teamviewer and hklm/software/teamviewer ( jika tidak ada berarti sudah terhapus otomatis ).
4> Ubah MAC Address menggunakan software macmakeup: http://www.gorlani.com/portal/projects/mac-makeup-the-original ( hanya 0.5 mb, cari link p aling bawah page ) save, ekstrak kemudian jalan macmakeup.exe klik generate random kemudian change selesai.
5> Bersihkan systems registry – download Eusing Cleaner http://www.eusing.com/free_system_cleaner/system_cleaner.htm pilih download site lalu save ( kapasitas 1.47 mb ).
6> Instal ulang team viewer portable atau team viewer versi lainya ( klo saya portable ). https://downloadap1.teamviewer.com/download/version_6x/TeamViewerPortable.zip
Senin, 01 Agustus 2016
AX : update data AX 2012
CONTOH :
static void UpdateCustomerCreditMax(str 30 AccountNum, real newMaximum) { CustTable custTable; ttsBegin; while select forUpdate custTable where custTable.AccountNum == AccountNum { custTable.CreditMax = newMaximum; custTable.update(); } ttsCommit; }
Senin, 25 Juli 2016
AX : Tutorial Class Data Contract for SSRS AX 2012
you can read on
http://www.artofcreation.be/2011/08/22/ax2012-sysoperation-part-1-data-contracts-and-service-operations/
http://www.artofcreation.be/2011/08/22/ax2012-sysoperation-part-1-data-contracts-and-service-operations/
Minggu, 24 Juli 2016
AX : Enabled Dissabled button di form List Page AX 2012
cara nya lihat di properti form ada interaction class..nah itu adalah class untuk mengatur disabled enabled button
(contoh itu di class purchtablelistpageinteracion)
(contoh itu di class purchtablelistpageinteracion)
Kamis, 14 Juli 2016
AX : Name and Table ID AX 2012
http://microsoft-dynamics-ax-erp.blogspot.co.id/2012/04/name-and-id-of-tables_13.html
AX : Unmarked Settlement AX 2012
Un-mark transactions marked for settlement
Scenario:
-
If you go to Vendors>>Functions>>Open transactions editing you can identify transactions that have been marked for settlement by the red hand in he "Is marked" column. Un-marking these transactions works only by finding the offset transaction and deleting the link from there.
Issue:
-
I came across transactions that have been identified as marked, however I did not know where the transactions are marked. The marking was created in one case because an update conflict occurred in the payment journal which cause the processing of the payment, casing the marked offset transaction to be lost but the transaction to be settled remained marked; in another case I think someone started to create a credit adjustment note, but deleted the credit adjustment before completing however the marking remained.
Investigation:
- In the open transactions editing form (Vendors>>Functions>>Open transactions editing or Customers>>Functions>>Open transactions editing) and find the problematic transaction.
- Go to Inquiries>>Specification and research the offset transactions. Try to un-mark the transaction with traditional means (i.e. Function>>Open transactions editing on the sales order etc.)
- If you find a problem an want to continue with removing the marking then right click on the record in "Open transactions editing", select "Record info">>"Show all fields" and make a note of the Record-Id.
-
The next step must be done in the AOT using the table browser to directly access the data of certain tables. This is dangerous and definitely not good practice. However I do not know better and would appreciate if someone could show me how to do it better.
-
The table SpecTrans contains all transactions marked for settlement. Find th record-id you previously made a note of in the column RefRecId.
-
Delete the found SpecTrans record to remove the marking.
Better solutions?
If you have a cleaner and better solution, please tell me how you do it?
Thank you
Thomas
Kamis, 30 Juni 2016
IT : Cara untuk melakukan format flashdisk FAT32 ke NTFS
1. Klik kanan pada My Computer, dan klik Manage
2. Klik pada Device Manager dan kemudian pilih Disk Drive seperti pada gambar di bawah :
3. Klik kanan pada USB Drive yang dipilih dan klik Properties. Klik pada tab Policies, Anda akan mendapatkan 2 pilihan yaitu "Optimize for quick removal" dan "Optimize for performance". Pilih pilihan kedia yaitu "Optimize for performance" (jika pengguna windows xp, vista dan 7) jika anda pengguna windows 8 dan windows 10 pilihlah yang Better Performance.
4. Klik Ok dan menuju ke My Computer. Klik kanan pada drive di My Computer dan polih Format. Pada File System pilih format NTFS dan klik start untuk memulai.
5. Selesai
Selasa, 28 Juni 2016
AX : Contoh Lain Query SUM di AX 2012
public void executeQuery()
{
Query query,queryline;
QueryRun qr, qrAPInvoice;
QueryBuildDataSource queryBuildDataSource,querylinesource;
//QueryBuildFieldList qbfl = queryBuildDataSource.fields();
QueryBuildRange queryBuildRange,queryrangeline;
// QueryBuildFieldList qbfl = queryBuildDataSource.fields();
Common common;
str recIds;
PurchDP_Header argsRecord;
LedgerJournalTrans ldjt;
//this.query().dataSourceNo(1).clearRanges();
// Get all the markupTrans recIds for the
// sales header and lines.
argsRecord = element.args().record();
recIds = argsRecord.Nomor_PurchDP;
query = new Query();
queryBuildDataSource = query.addDataSource(tableNum(LedgerJournalTrans));
queryBuildRange = queryBuildDataSource.addRange(fieldNum(LedgerJournalTrans,Nomor_DP));
// If no RecIds for markupTrans are associated with the sales order, passing in an empty
// string was causing there to be no filter on recId and returning all records.
if(recIds)
{
queryBuildRange.value(queryValue(recIds));
// PurchDP_Header_ds.object(fieldNum(PurchDP_Header, VendorAccount)).allowEdit(false);
}
else
{
queryBuildRange.value(SysQuery::valueEmptyString());
}
//QBFL SUM
queryBuildDataSource.addSelectionField(fieldNum(LedgerJournalTrans,AmountCurDebit),SelectionField::Sum);
queryBuildDataSource.addSelectionField(fieldNum(LedgerJournalTrans,AmountCurCredit),SelectionField::Sum);
queryBuildDataSource.addSortField(fieldnum(LedgerJournalTrans,journalnum));
queryBuildDataSource.addSortField(fieldnum(LedgerJournalTrans,voucher));
queryBuildDataSource.addSortField(fieldnum(LedgerJournalTrans,nomor_dp));
queryBuildDataSource.addSortField(fieldnum(LedgerJournalTrans,nomor_pa));
queryBuildDataSource.addSortField(fieldnum(LedgerJournalTrans,amountdp));
queryBuildDataSource.orderMode(OrderMode::GroupBy);
qr = new QueryRun(query);
while (qr.next())
{
ldjt = qr.get(tableNum(LedgerJournalTrans));
LedgerJournalTransTemp.clear();
LedgerJournalTransTemp.Nomor_DP = ldjt.Nomor_DP;
LedgerJournalTransTemp.Nomor_PA = ldjt.Nomor_PA;
LedgerJournalTransTemp.Voucher = ldjt.Voucher;
LedgerJournalTransTemp.JournalNum = ldjt.JournalNum;
LedgerJournalTransTemp.AmountCurDebit = ldjt.AmountCurDebit;
LedgerJournalTransTemp.AmountCurCredit = ldjt.AmountCurCredit;
LedgerJournalTransTemp.AmountDP = ldjt.AmountDP;
LedgerJournalTransTemp.insert();
}
super();
}
{
Query query,queryline;
QueryRun qr, qrAPInvoice;
QueryBuildDataSource queryBuildDataSource,querylinesource;
//QueryBuildFieldList qbfl = queryBuildDataSource.fields();
QueryBuildRange queryBuildRange,queryrangeline;
// QueryBuildFieldList qbfl = queryBuildDataSource.fields();
Common common;
str recIds;
PurchDP_Header argsRecord;
LedgerJournalTrans ldjt;
//this.query().dataSourceNo(1).clearRanges();
// Get all the markupTrans recIds for the
// sales header and lines.
argsRecord = element.args().record();
recIds = argsRecord.Nomor_PurchDP;
query = new Query();
queryBuildDataSource = query.addDataSource(tableNum(LedgerJournalTrans));
queryBuildRange = queryBuildDataSource.addRange(fieldNum(LedgerJournalTrans,Nomor_DP));
// If no RecIds for markupTrans are associated with the sales order, passing in an empty
// string was causing there to be no filter on recId and returning all records.
if(recIds)
{
queryBuildRange.value(queryValue(recIds));
// PurchDP_Header_ds.object(fieldNum(PurchDP_Header, VendorAccount)).allowEdit(false);
}
else
{
queryBuildRange.value(SysQuery::valueEmptyString());
}
//QBFL SUM
queryBuildDataSource.addSelectionField(fieldNum(LedgerJournalTrans,AmountCurDebit),SelectionField::Sum);
queryBuildDataSource.addSelectionField(fieldNum(LedgerJournalTrans,AmountCurCredit),SelectionField::Sum);
queryBuildDataSource.addSortField(fieldnum(LedgerJournalTrans,journalnum));
queryBuildDataSource.addSortField(fieldnum(LedgerJournalTrans,voucher));
queryBuildDataSource.addSortField(fieldnum(LedgerJournalTrans,nomor_dp));
queryBuildDataSource.addSortField(fieldnum(LedgerJournalTrans,nomor_pa));
queryBuildDataSource.addSortField(fieldnum(LedgerJournalTrans,amountdp));
queryBuildDataSource.orderMode(OrderMode::GroupBy);
qr = new QueryRun(query);
while (qr.next())
{
ldjt = qr.get(tableNum(LedgerJournalTrans));
LedgerJournalTransTemp.clear();
LedgerJournalTransTemp.Nomor_DP = ldjt.Nomor_DP;
LedgerJournalTransTemp.Nomor_PA = ldjt.Nomor_PA;
LedgerJournalTransTemp.Voucher = ldjt.Voucher;
LedgerJournalTransTemp.JournalNum = ldjt.JournalNum;
LedgerJournalTransTemp.AmountCurDebit = ldjt.AmountCurDebit;
LedgerJournalTransTemp.AmountCurCredit = ldjt.AmountCurCredit;
LedgerJournalTransTemp.AmountDP = ldjt.AmountDP;
LedgerJournalTransTemp.insert();
}
super();
}
AX : Sum di AX 2012
You can use the following code:
QueryBuildFieldList qbfl = qbds.fields();
qbds = q.addDataSource(tablenum(SalesLine));
//QBFL
qbfl.addField(fieldNum(SalesLine,SalesQty),SelectionField::Sum);
qbds.addSortField(fieldnum(SalesLine,ItemId));
qbds.orderMode(OrderMode::GroupBy);
qr = new QueryRun(q);
while(qr.next())
{
salesLine = qr.get(tablenum(SalesLine));
info(strfmt('Item Id =%1, Qty = %2',salesLine.ItemId,salesLine.SalesQty));
}
QueryBuildFieldList qbfl = qbds.fields();
qbds = q.addDataSource(tablenum(SalesLine));
//QBFL
qbfl.addField(fieldNum(SalesLine,SalesQty),SelectionField::Sum);
qbds.addSortField(fieldnum(SalesLine,ItemId));
qbds.orderMode(OrderMode::GroupBy);
qr = new QueryRun(q);
while(qr.next())
{
salesLine = qr.get(tablenum(SalesLine));
info(strfmt('Item Id =%1, Qty = %2',salesLine.ItemId,salesLine.SalesQty));
}
Rabu, 22 Juni 2016
Query : Query Pengurangan data Min kesatu dengan Min Kedua
contoh :
SELECT a.NM_SHIFT, MIN( a.OFFERED ) AS c, ( (
SELECT b.OFFERED
FROM `patern_shift` b
WHERE b.NM_SHIFT = a.NM_SHIFT
ORDER BY b.OFFERED ASC
LIMIT 1 , 1
) - MIN( a.OFFERED )
) AS diff
FROM `patern_shift` a
GROUP BY a.NM_SHIFT
flag merag menunjukan data Min kedua
flag biru menunjukan data Min kesatu
SELECT a.NM_SHIFT, MIN( a.OFFERED ) AS c, ( (
SELECT b.OFFERED
FROM `patern_shift` b
WHERE b.NM_SHIFT = a.NM_SHIFT
ORDER BY b.OFFERED ASC
LIMIT 1 , 1
) - MIN( a.OFFERED )
) AS diff
FROM `patern_shift` a
GROUP BY a.NM_SHIFT
flag merag menunjukan data Min kedua
flag biru menunjukan data Min kesatu
Rabu, 15 Juni 2016
Teamviewer : Reset password teamviewer tanpa instal ulang
[16:16, 6/15/2016] +62 813-3299-4153: [14:49, 6/7/2016] budi maho lagi: pakai tmac
[14:51, 6/7/2016] budi maho lagi: https://technitium.com/
[14:51, 6/7/2016] budi maho lagi: uninstall teamviewer
[14:52, 6/7/2016] budi maho lagi: http://dyandraraditya.blogspot.co.id/2015/05/mengatasi-team-viewer-expired.html
[16:16, 6/15/2016] +62 813-3299-4153: kemarin saya coba bisa
[16:16, 6/15/2016] +62 813-3299-4153: tanpa instal ulang
[14:51, 6/7/2016] budi maho lagi: https://technitium.com/
[14:51, 6/7/2016] budi maho lagi: uninstall teamviewer
[14:52, 6/7/2016] budi maho lagi: http://dyandraraditya.blogspot.co.id/2015/05/mengatasi-team-viewer-expired.html
[16:16, 6/15/2016] +62 813-3299-4153: kemarin saya coba bisa
[16:16, 6/15/2016] +62 813-3299-4153: tanpa instal ulang
AX : Query Delete Table AX 2012
Contoh :
ttsBegin; while select forUpdate myTable where myTable.AccountNum == '1000' { myTable.delete(); } ttsCommit;
atau
static void DeleteMultiRow1bJob(Args _args) { MyWidgetTable tabWidget; // extends xRecord. ; ttsBegin; while select forUpdate tabWidget where tabWidget .quantity <= 100 { tabWidget .delete(); } ttsCommit; }
atau
static void DeleteMultiRow1aJob(Args _args) { MyWidgetTable tabWidget; ; delete_from tabWidget where tabWidget .quantity <= 100; }
Selasa, 07 Juni 2016
Query : Query Create Table and Insert from other Table ( mssql )
select * into purchdplines from AGREEMENTLINE where 1=0;
Selasa, 31 Mei 2016
AX : query range today + dan today - AX 2012 View
you can add value with this function :
(dayRange(-60,60))
-60 = today -60
60 = today + 60 day
(dayRange(-60,60))
-60 = today -60
60 = today + 60 day
AX :Using Methods in Table Filters & Query Ranges in Dynamics AX 2012 (http://nuxulu.com)
In Dynamics AX, there is a class called SysQueryRangeUtil
that can be utilized in both query ranges and table filters. Using
methods from this class allow you to be very precise about what dates
you want to use in reports or for filtering your data.
Let’s say you have a report that you always
want to run to see orders with shipping dates of the next day. It is
possible to do so by using one of the methods from the SysQueryRangeUtil. The
use of the letter ‘t’ will work for today’s date, but when you try to
add days to it, it doesn’t work in reports. Instead, I will use the currentdate() method and add 1 to it.
Note: All methods & expressions must be surrounded by parentheses as shown below.
Note: All methods & expressions must be surrounded by parentheses as shown below.
Figure 1 – Filtering the requested ship dates in an AX query for tomorrow (current day + 1)
On any form with a grid, you filter your data by pressing Ctrl+G.
If I were to want to see open customer invoices from the last 90 days, I
would filter my open customer invoices form and use the method(dayRange(-90,0)).
The first number represents how many months backward from this month,
and the second represents how many months forward. The same sorts of
things can be done for themonthRange(), yearRange(), and dateRange()
methods. The best part about this is that you can of course save these
filters to create views that you might use on a daily basis.
Figure 2 – Searching the grid for the past 90 days
If you are creating your query ranges in
code, these methods can also be utilized whenever you are setting them.
Definitely be sure to check out the SysQueryRangeUtil class as there are
many more methods to use.
Kamis, 26 Mei 2016
AX : Get Company info AX 2012
Contoh :
salesordersheadertmp.CompanyAddress = CompanyInfo::find().postalAddress().Address;
salesordersheadertmp.CompanyPhone = CompanyInfo::find().phone();
salesordersheadertmp.CompanyName =CompanyInfo::find().Name();
salesordersheadertmp.CompanyTeleFax = CompanyInfo::find().teleFax();
salesordersheadertmp.CompanyGiro = CompanyInfo.Giro;
salesordersheadertmp.CompanyCoRegNum = CompanyInfo.CoRegNum;
salesordersheadertmp.CompanyEnterpriseNumber = CompanyInfo.EnterpriseNumber;
salesordersheadertmp.CompanyAddress = CompanyInfo::find().postalAddress().Address;
salesordersheadertmp.CompanyPhone = CompanyInfo::find().phone();
salesordersheadertmp.CompanyName =CompanyInfo::find().Name();
salesordersheadertmp.CompanyTeleFax = CompanyInfo::find().teleFax();
salesordersheadertmp.CompanyGiro = CompanyInfo.Giro;
salesordersheadertmp.CompanyCoRegNum = CompanyInfo.CoRegNum;
salesordersheadertmp.CompanyEnterpriseNumber = CompanyInfo.EnterpriseNumber;
Minggu, 22 Mei 2016
AX : Query Value +30 atau -30 di AX 2012
bisa dicoba ini
DateTimeUtil::addMonths(DateTimeUtil::utcNow(), -1))
-1 maksudnya 1 bulan
atau ini
>= Now() + 30
atau coba ini juga
>= today() + 30
DateTimeUtil::addMonths(DateTimeUtil::utcNow(), -1))
-1 maksudnya 1 bulan
atau ini
>= Now() + 30
atau coba ini juga
>= today() + 30
Rabu, 18 Mei 2016
AX : Method untuk > atau < apabila kondisi date
Method untuk tanggal kurang dari hari ini
(lessThanUtcNow())
Method untuk tanggal lebih dari hari ini
validTo (greaterThanUtcNow())
(lessThanUtcNow())
Method untuk tanggal lebih dari hari ini
validTo (greaterThanUtcNow())
Wifi Lenovo G40-70 Tidak Nyala ( not detected ) - http://kbhb86.blogspot.co.id
Sering kali
terjadi hal seperti ini wifi tidak nyala / not conected, padahal semua
driver sudah terinstal. Lihat cara instal driver wifi dan cara
mengaktifkannya di bawah ini :
1. Instal
terlebih dahulu driver energy manager, ikuti langkah - langkahnya hingga
selesai sampai muncul perintah selesai dan restart.
Gambar 1.1 |
Gambar 1.2 |
Selasa, 17 Mei 2016
Query : Menghitung Jumlah Karakter
menggunakan length, contoh
SELECT kode_produk, length(kode_produk) AS panjang FROM ms_produk LIMIT 0,10;
Senin, 16 Mei 2016
AX SSRS : IF Condition with enter ( TRUE )
=First(Fields!VendAddress.Value, "InvoiceHeadPOTmpDS")
+IIF(IsNothing(First(Fields!VendPhone.Value, "InvoiceHeadPOTmpDS")) OR First(Fields!VendPhone.Value, "InvoiceHeadPOTmpDS") = ""
,"", VBCRLF+First(Fields!VendPhone.Value, "InvoiceHeadPOTmpDS") )
+IIF(IsNothing(First(Fields!VendFax.Value, "InvoiceHeadPOTmpDS")) OR First(Fields!VendFax.Value, "InvoiceHeadPOTmpDS") = ""
,"",VBCRLF+First(Fields!VendFax.Value, "InvoiceHeadPOTmpDS") )
+IIF(IsNothing(First(Fields!VendPhone.Value, "InvoiceHeadPOTmpDS")) OR First(Fields!VendPhone.Value, "InvoiceHeadPOTmpDS") = ""
,"", VBCRLF+First(Fields!VendPhone.Value, "InvoiceHeadPOTmpDS") )
+IIF(IsNothing(First(Fields!VendFax.Value, "InvoiceHeadPOTmpDS")) OR First(Fields!VendFax.Value, "InvoiceHeadPOTmpDS") = ""
,"",VBCRLF+First(Fields!VendFax.Value, "InvoiceHeadPOTmpDS") )
Minggu, 15 Mei 2016
AX SSRS : Menggabungkan Field dan Menambahkan Enter di SSRS Report
contoh :
= First(Fields!Name.Value, "DataSet1") & VBCRLF &
First(Fields!Address1.Value, "DataSet1") & VBCRLF &
IIF(First(Fields!Address2.Value, "DataSet1") Is Nothing, "", First(Fields!Address2.Value, "DataSet1") & VBCRLF) &
IIF(First(Fields!Address3.Value, "DataSet1") Is Nothing, "", First(Fields!Address3.Value, "DataSet1") & VBCRLF) &
First(Fields!ZipCode.Value, "DataSet1")
Fungsi & adalah untuk menggabungkan field
VBCRLF fungsinya sebagai petunjuk enter
Jumat, 13 Mei 2016
Query : Query Update With Concat Substr
Contoh :
update karyawan set joindate=CONCAT(SUBSTR(SSN,1,4),"-",SUBSTR(SSN,5,2),"-", SUBSTR(SSN,7,2))
update karyawan set joindate=CONCAT(SUBSTR(SSN,1,4),"-",SUBSTR(SSN,5,2),"-", SUBSTR(SSN,7,2))
Query : Contoh Query Concat With Substr
Contoh :
SELEcT name,ssn, CONCAT(SUBSTR(SSN,1,4),"-",SUBSTR(SSN,5,2),"-", SUBSTR(SSN,7,2)) from karyawan
SELEcT name,ssn, CONCAT(SUBSTR(SSN,1,4),"-",SUBSTR(SSN,5,2),"-", SUBSTR(SSN,7,2)) from karyawan
Rabu, 11 Mei 2016
Excel : If di Excel (http://rumuslengkap.com)
Rumus IF merupakan salah satu fungsi paling umum yang digunakan dalam Microsoft Excel.
Fungsi IF atau yang juga bisa diartikan “jika”, digunakan untuk
mengecek suatu kondisi. Apabila kondisi terpenuhi maka fungsi akan
mengambil suatu nilai, dan sebaliknya apabila kondisi tersebut tidak
terpenuhi maka akan diambil nilai yang lain. dengan kata lain, fungsi IF
disebut fungsi syarat. Jika suatu nilai mempunyai syarat dan dapat
bernilai benar apabila syarat terpenuhi serta bernilai salah jika syarat
tidak terpenuhi.
Excel : Formula If dengan Warna (copas http://kangmansyur.blogspot.co.id)
Bagaimana
membuat sebuah grade atas nilai suatu mahasiswa tertentu, dan bagaimana
memberikan pewarnaan di exel atas berbagai grade nilai mahasiswa
tersebut. Untuk contohnya mari kita coba di excel sebagai berikut
Kamis, 05 Mei 2016
AX ; Query Join AX
qbdsCIT = query.addDataSource(tableNum(CustInvoiceTrans));
qbdsAgreementLineReleasedLine = qbdsCIT.addDataSource(tableNum(AgreementLineReleasedLineUnion));
qbdsAgreementLineReleasedLine.joinMode(JoinMode::ExistsJoin);
qbdsAgreementLineReleasedLine.addLink(fieldNum(CustInvoiceTrans, RecId),
fieldNum(AgreementLineReleasedLineUnion,CustInvoiceTrans));
qbdsAgreementLine = qbdsAgreementLineReleasedLine.addDataSource(tableNum(AgreementLine));
qbdsAgreementLine.joinMode(JoinMode::ExistsJoin);
qbdsAgreementLine.addLink(fieldNum(AgreementLineReleasedLineUnion, AgreementLine),
fieldNum(AgreementLine, RecId));
qbdsAgreementHeader = qbdsAgreementLine.addDataSource(tablenum (SalesAgreementHeader));
qbdsAgreementHeader.joinMode(JoinMode::ExistsJoin);
qbdsAgreementHeader.addLink(fieldNum(AgreementLine, Agreement),
fieldNum(SalesAgreementHeader, RecId));
qbdsAgreementHeader.addRange(fieldNum(SalesAgreementHeader, Salesnumbersequence)).value(nomorsacari);
qr = new QueryRun(query);
while (qr.next())
{
CT = qr.Get(tableNum(CustInvoiceTrans));
//ID = qr.Get(tableNum(InventDim));
InvoiceAndFreeTaxTmp.clear();
InvoiceAndFreeTaxTmp.InvoiceId = CT.InvoiceId;
InvoiceAndFreeTaxTmp.tanggal = CT.InvoiceDate;
InvoiceAndFreeTaxTmp.nmrSO = CT.OrigSalesId;
InvoiceAndFreeTaxTmp.licenseplate=CT.LicensePlate();
InvoiceAndFreeTaxTmp.ka=CT.KadarAir();
InvoiceAndFreeTaxTmp.CIT_SDL=CT.SourceDocumentLine;
//InvoiceAndFreeTaxTemp.licenseplate=CustInvoicePackingSlip::PackAndLicense(0, CT.RecId);
InvoiceAndFreeTaxTmp.KG=CT.Qty;
//InvoiceAndFreeTaxTmp.ka=CustInvoicePackingSlip::KadarAirs(0, CT.RecId);
InvoiceAndFreeTaxTmp.refraksipercent=CT.markupAmountPercent();
InvoiceAndFreeTaxTmp.refraksipcs=CT.markupAmountPcs();
InvoiceAndFreeTaxTmp.jumlah=CT.LineInvoiceAmount();
InvoiceAndFreeTaxTmp.harga=CT.PriceUnit;
cittvalue=CT.SourceDocumentLine;
//info(int642str(cittvalue));
InvoiceAndFreeTaxTmp.komoditi=CT.Name;
if(CT.B2BSupplier()!="")
{
InvoiceAndFreeTaxTmp.supplier=CT.B2BSupplier();
}
else
{
InvoiceAndFreeTaxTmp.supplier=CT.inventLocationId();
}
if(CT.OrigSalesId=="")
{
InvoiceAndFreeTaxTmp.FreeTax=1;
InvoiceAndFreeTaxTmp.Jenis='FREETEXT';
}
InvoiceAndFreeTaxTmp.insert();
////////////////////////////////////////////////////////////////
///
}
qbdsAgreementLineReleasedLine = qbdsCIT.addDataSource(tableNum(AgreementLineReleasedLineUnion));
qbdsAgreementLineReleasedLine.joinMode(JoinMode::ExistsJoin);
qbdsAgreementLineReleasedLine.addLink(fieldNum(CustInvoiceTrans, RecId),
fieldNum(AgreementLineReleasedLineUnion,CustInvoiceTrans));
qbdsAgreementLine = qbdsAgreementLineReleasedLine.addDataSource(tableNum(AgreementLine));
qbdsAgreementLine.joinMode(JoinMode::ExistsJoin);
qbdsAgreementLine.addLink(fieldNum(AgreementLineReleasedLineUnion, AgreementLine),
fieldNum(AgreementLine, RecId));
qbdsAgreementHeader = qbdsAgreementLine.addDataSource(tablenum (SalesAgreementHeader));
qbdsAgreementHeader.joinMode(JoinMode::ExistsJoin);
qbdsAgreementHeader.addLink(fieldNum(AgreementLine, Agreement),
fieldNum(SalesAgreementHeader, RecId));
qbdsAgreementHeader.addRange(fieldNum(SalesAgreementHeader, Salesnumbersequence)).value(nomorsacari);
qr = new QueryRun(query);
while (qr.next())
{
CT = qr.Get(tableNum(CustInvoiceTrans));
//ID = qr.Get(tableNum(InventDim));
InvoiceAndFreeTaxTmp.clear();
InvoiceAndFreeTaxTmp.InvoiceId = CT.InvoiceId;
InvoiceAndFreeTaxTmp.tanggal = CT.InvoiceDate;
InvoiceAndFreeTaxTmp.nmrSO = CT.OrigSalesId;
InvoiceAndFreeTaxTmp.licenseplate=CT.LicensePlate();
InvoiceAndFreeTaxTmp.ka=CT.KadarAir();
InvoiceAndFreeTaxTmp.CIT_SDL=CT.SourceDocumentLine;
//InvoiceAndFreeTaxTemp.licenseplate=CustInvoicePackingSlip::PackAndLicense(0, CT.RecId);
InvoiceAndFreeTaxTmp.KG=CT.Qty;
//InvoiceAndFreeTaxTmp.ka=CustInvoicePackingSlip::KadarAirs(0, CT.RecId);
InvoiceAndFreeTaxTmp.refraksipercent=CT.markupAmountPercent();
InvoiceAndFreeTaxTmp.refraksipcs=CT.markupAmountPcs();
InvoiceAndFreeTaxTmp.jumlah=CT.LineInvoiceAmount();
InvoiceAndFreeTaxTmp.harga=CT.PriceUnit;
cittvalue=CT.SourceDocumentLine;
//info(int642str(cittvalue));
InvoiceAndFreeTaxTmp.komoditi=CT.Name;
if(CT.B2BSupplier()!="")
{
InvoiceAndFreeTaxTmp.supplier=CT.B2BSupplier();
}
else
{
InvoiceAndFreeTaxTmp.supplier=CT.inventLocationId();
}
if(CT.OrigSalesId=="")
{
InvoiceAndFreeTaxTmp.FreeTax=1;
InvoiceAndFreeTaxTmp.Jenis='FREETEXT';
}
InvoiceAndFreeTaxTmp.insert();
////////////////////////////////////////////////////////////////
///
}
Senin, 25 April 2016
IT : Mengatasi Kolom Excel Berubah Menjadi Angka
kejadian ini jarang terjadi..namun bisa terjadi, jadi kolom yang seharusnya Huruf berubah menjadi Angka
Apabila mengalami hal tersebut tinggal masuk ke File - Excel Option lalu unchecked field dibawah
setelah itu langsung normal kembali
Apabila mengalami hal tersebut tinggal masuk ke File - Excel Option lalu unchecked field dibawah
setelah itu langsung normal kembali
Langganan:
Postingan (Atom)