Below is the code for three type of combo values : Asset, Ledger & Vendor.
Just write the code below on the clicked method of the button thru which u
need to open the form.
*LedgerVendAsset_Combo is the name of the combo field
*LedgerVendAsset is the name of the Base enum
*account is the name of the field where the lookup of the account number is
displayed
void clicked()
{
AssetTable assetTable;
LedgerTable ledgerTable;
VendTable vendTable;
FormRun formRun;
Args args = new Args();
;
super();
switch(LedgerVendAsset_Combo.valueStr())
{
case enum2str(LedgerVendAsset::Asset):
assetTable = AssetTable::find(account.valueStr());
args.record(assetTable);
args.name(formstr(AssetTable));
break;
case enum2str(LedgerVendAsset::Ledger):
ledgerTable = LedgerTable::find(account.valueStr());
args.record(LedgerTable);
args.name(formstr(LedgerTable));
break;
case enum2str(LedgerVendAsset::Vendor):
vendTable = VendTable::find(account.valueStr());
args.record(vendTable);
args.name(formstr(VendTable));
break;
default:
break;
}
formRun = ClassFactory.formRunClass(args);
formRun.init();
formRun.run();
formRun.wait();
}
----- Original Message -----
From: "manojkumar_asp" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Monday, December 19, 2005 6:49 PM
Subject: [development-axapta] Opening a form
> Hi All,
> I have created a form where there are different accounts for
> ledger,Fixed assets, vendor,Cost accounting listed in combo box.When i
> select a account type and click the lookup form the account number and
> name is displayed, Now i want to add a button next to the form and
> when selecting the particular account number from lookup and pressing
> the button should open the ledger form or vendor form or etc with only
> the account number i selected or can display all the value but the
> selected account number highlighted. Please give me any solutions.
> Thanks in advance.
>
> Regards,
> Manoj
>
>
>
>
>
>
>
>
>
> Yahoo! Groups Links
>
>
>
>
>
>
>
SPONSORED LINKS
| Computer part | Programming languages | Microsoft axapta |
| Support exchange |
YAHOO! GROUPS LINKS
- Visit your group "development-axapta" on the web.
- To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
- Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.

