How from an Access Currency field I populate a hidden field
//out.println("<input type=\"hidden\" name=\"price" + plantNo + "\" value=\"" + rs.getString(5) + "\">");
The above found to give errors... how from Access Currency field like price=
rs.getString(5)
I populate a hidden field ? How do it in MySQL ?
Servlets upon compilation(or update) needed server restart to rerun (updated) ?
if I insert
rs.getString(5) // field5 = currency field MS-Access DB
it doesn't work, but if insert
"8.9"
work in value of hidden field , where error ?
out.println("<input type=\"hidden\" name=\"price" + plantNo + "\" value=\"" + rs.getString(5) + "\">"); // "8.9"
Access Currency field is/corresponds double in java ?
Similar Messages
-
How to control access to a document library based on fields of the list?
Hi,
I need to give access to a document library but the users who need permission are unknown until the form
is submitted to the document library. The 2 users information are in 2 fields of the form. I created a infopath form and a workflow with it.
I need to give the "CreatedBy" user, the person who completed and submitted the form, and the
Requester (a data field on the form), both need access to the new document library or just to the forms they submitted. How do I setup access for the createor and requester of the form? These are unknown until the time of the form submission and
it's dynamic.
Anyway to implement this in SP? If not what about coding for when the form is loaded. Can
someone point me to a sample coding for ref fields in the form when form is first loaded up? Also, how to redirect to a access denied view in the code.
Thank you.It's not easy OOTB but it can be done if you either use code or use some code someone else created.
Have a look at this on codeplex
https://spdactivities.codeplex.com/wikipage?title=Grant%20Permission%20on%20Item -
Need to compare two fields and populate the other fields.
Hi All,
I have scenario like this.
DATA: text1(150) type C
VALUE 'Step: SHORT DUMP; Scenario: PRE; Date :09.07.2007. Time :13:08:33.'.
DATA: text2(150) TYPE C
VALUE 'Step: &; Scenario: &; &',
DATA: text_A(150) TYPE C,
text_B(150) TYPE C,
text_C(150) TYPE C.
Now I need to compare text1 and text2 and populate text_A, text_B and text_C as follows.
text_A = SHORT DUMP
text_B = PRE
text_C = Date :09.07.2007. Time :13:08:33.
Basically I need to fill text_A, text_A and text_A with the values in text1 which are replaced by '&'.
Can anyone suggest me a code snippet to do it?
Thanks in advance.
Regards
AnkitSorry for slow response - I'm in a different timezone I think... Well it's not a short algorithm, but you could try something like the following (there's probably a sweeter algorithm, but this is what occured to me overnight)... I realise that it's not foolproof as you could have words substituted in for the "&" that also appear in the original message text and that would skew the results...
Jonathan
report zlocal_jc_get_msgvars.
types:
gty_char150(150) type c.
parameters:
p_text_1 type gty_char150 lower case,
p_text_2 type gty_char150 lower case.
initialization.
perform initialization.
start-of-selection.
perform extract_msgv.
*& Form initialization
form initialization.
*" Default screen variables
concatenate
'Step: SHORT DUMP; Scenario: PRE;'
'Date :09.07.2007. Time :13:08:33.'
into p_text_1 separated by space.
p_text_2 = 'Step: &; Scenario: &; &'.
endform. "initialization
*& Form extract_msgv
form extract_msgv.
*" Work out the values that have been substituted
*" into p_text2 to make p_text1
data:
l_text_a type gty_char150,
l_text_b type gty_char150,
l_text_c type gty_char150,
l_text_d type gty_char150,
l_tabix_1 type i,
l_tabix_2 type i,
l_word_1 type gty_char150,
lt_word_1 type gty_char150 occurs 10,
l_word_2 type gty_char150,
lt_word_2 type gty_char150 occurs 10,
l_result type gty_char150,
l_tabix type sy-tabix,
l_tabix_next type sy-tabix,
l_tabix_from type sy-tabix,
l_tabix_to type sy-tabix,
lt_tabix type sy-tabix occurs 4,
lt_result type gty_char150 occurs 10.
*" Break the strings into words
split p_text_1 at space into table lt_word_1.
split p_text_2 at space into table lt_word_2.
format reset.
format color col_total.
write: / p_text_1(80).
write: / p_text_2(80).
format reset.
*" Look at where the words in the shorter string appear in the longer
loop at lt_word_2 into l_word_2.
add 1 to l_tabix_2.
write: / 'P_TEXT_2, Word', l_tabix_2, l_word_2.
if l_word_2+0(1) = '&'. "placemarker
continue.
endif.
*" examine the expanded version
read table lt_word_1 into l_word_1
with key = l_word_2.
if not sy-subrc is initial.
write: /
'ERROR: Word not found in expanded version' color col_negative.
continue.
endif.
l_tabix_1 = sy-tabix. "Where we found word from short msg
append l_tabix_1 to lt_tabix.
endloop.
*" add pointer to end of list of words too
describe table lt_word_1 lines l_tabix_1.
add 1 to l_tabix_1. "because we subtract 1 below...
append l_tabix_1 to lt_tabix.
loop at lt_tabix into l_tabix_from.
l_tabix = sy-tabix.
write: / l_tabix_from.
*" get the range of words we want by getting next tabix row
*" and subtracting 1
l_tabix_next = l_tabix.
add 1 to l_tabix_next.
read table lt_tabix into l_tabix_to index l_tabix_next.
if not sy-subrc is initial. "no more words...
exit.
endif.
add 1 to l_tabix_from.
subtract 1 from l_tabix_to.
loop at lt_word_1 into l_word_1
from l_tabix_from to l_tabix_to.
write: / l_word_1 color col_positive.
* Push into text_A, text_B, text_C, text_D
case l_tabix.
when 1.
concatenate l_text_A l_word_1 into l_text_a
separated by space.
when 2.
concatenate l_text_b l_word_1 into l_text_b
separated by space.
when 3.
concatenate l_text_c l_word_1 into l_text_c
separated by space.
when 4.
concatenate l_text_d l_word_1 into l_text_d
separated by space.
endcase.
endloop.
endloop.
uline.
format reset.
format color col_group.
write: / 'TEXT_A', l_text_a(80).
write: / 'TEXT_B', l_text_b(80).
write: / 'TEXT_C', l_text_c(80).
write: / 'TEXT_D', l_text_d(80).
format reset.
endform. "extract_msgv -
Mandatory for Visable field but not for hidden field
Hi All,
I have a couple of radio buttons (Yes and No) when the user selects Yes they are then prompted for the date this happend.
How can i make the Date field mandatory if they select yes but not if they select no. I have tried making the date field mandatory but it throughs the obvious error if it is hidden.Hi George, thanks for your reply.
The way i hide and show the date box at the moment is by using the Show/Hide field action under the properties of the radio buttons.
Thx -
How to store list item in hidden field?
I want to store the list item value of SharePoint 2013 in a input type hidden field.
And then want to get that items client side.
How can I store that value to <Input type="Hidden"/> field?
Thanks in Advance.Hi,
If you want to get the value of list item from client side, a recommended way is using
JavaScript Client Object Model.
With JavaScript Client Object Model, we can write code with JavaScript to access SharePoint objects from client side dynamically.
The links below about JavaScript Client Object Model for your reference:
http://msdn.microsoft.com/en-us/library/office/hh185006(v=office.14).aspx
More information about JavaScript Client Object Model:
http://msdn.microsoft.com/en-us/library/office/hh185011(v=office.14).aspx
http://msdn.microsoft.com/en-us/library/office/hh185015(v=office.14).aspx
Best regards
Patrick Liang
TechNet Community Support -
Display hidden fields in output list when submitting a report from another
I have a report A that is submitting another report B and exporting the list to memory. Report B is a standard report and cannot be executed on its own.
SUBMIT ReportB
WITH p_select = p_select
EXPORTING LIST TO MEMORY
AND RETURN.
CALL FUNCTION 'LIST_FROM_MEMORY'
TABLES
listobject = t_list
EXCEPTIONS
not_found = 1
OTHERS = 2.
CALL FUNCTION 'LIST_TO_ASCI'
TABLES
listasci = t_ascitab
listobject = t_list
EXCEPTIONS
empty_list = 1
list_index_invalid = 2
OTHERS = 3.
The output of report B displays an ALV report, default layout of this ALV has a number of hidden fields. So when I am exporting the list to memory, the returned internal table finally extracted (t_ascitab) has only the default fields and not the hidden fields.
The default layout of the standard report B cannot be altered (as per requirement).
Is there any way the hidden fields of the output of report B can be returned to report A??Hi ,
You have to Set layout of report B as per your requirment .
There is also other method
You can include Reportb in main report and access internal table data for further processing .
regards
Deepak.
Edited by: Deepak Dhamat on Aug 25, 2011 7:59 AM -
Customer no to populate the Assignment field for Sales A/c using sort key
Dear All,
In 6.0, I am trying to get the Customer number to populate the Assignment field for Sales Account
We have set the sales account to a 031 sort key - sort by customer, in FS00. When 031 is set, SAP goes to the BSEG table and looks at the KUNNR (customer) field and populates the Assignment field with what is in the KUNNR field of BSEG.
The problem is: the customer number (KUNNR) does not contain any data in BSEG.
The KUNNR field of all the other account lines for the document number are blank.
Is it possible to bring the field in the General Ledger display?
Does anyone know of a user exit or other solution?
Thanks,
GovHi,
Check with SD consultant and use Copy control. -
How to populate the address field in real time from backend?
Hi Guys,
I want to populate the address field in srm portal when creating Shopping Cart. I got the data by using some BADI functions. Now the problem is I am not getting the structure/table where I should add that address so that it can reflect in the address field of shopping cart.
Can anyone help me out?
Regards,
Virendra KediaJoe - Work backwards from the value generated during the execution of the trigger. You have the value there so you could save it into a package variable right then (create a package with a variable and assign the value to the variable). Then create a process on the page (after the DML process) to assign the value of your package variable to a page item. Then in the branch back to page 1, pass the item. (Or without messing with the branch, the process could simply assign the package variable directly the the page 1 item -- :P1_ITEM := my_package.my_var; ).
An alternative would be to use the "returning into" feature of DML to capture the PK of the created record into an item. Then the next page process could use the PK to fetch the new row and get the dbname value for passing to page 1.
Another option would be to update session state directly in the trigger.
Scott -
How to populate a hidden form field with a value passed from another page
I'm using PHP/MySQL and DW CS4.
I am trying to obtain the external key for a table, and include it as a hidden field in a form for a second table.
The user selects a "need" from a list and is taken to a new page which displays the need selected in the prior page and a form the user can fill out with details of his offer, there should also be a hidden field in this form that contains the index to the needs table, this hidden field holds the external key. Most of the code is working, except for populating the hidden field with the external key. I have proven(by printing it to the screen) that I have obtained the external key and stored it in a variable ($saveNeedId) . What I'm unable to do is assign this variable to the hidden field in the form I'm about to store in a table. Sometimes I get zero and sometimes I get the index to the first need in the table. This ought to be simple but I can't get it to work, I must be missing something obvious - still very new to PHP.
Here's the code that sets up the variable and prints it to the screen for test purposes
$saveNeedId = "-1";
if (isset($_GET['needId'])) {
$saveNeedId = $_GET['needId'];
print $saveNeedId;
Here's the code that sets up the hidden fields in the form, the one I'm trying to set up is the first one, needId
<input type="hidden" name="needId" value="<?php echo $row_rsNeedsUnmet['needId']; ?>" />
<input type="hidden" name="offerId" value="" />
<input type="hidden" name="MM_insert" value="form1" />
The page where the user sees the list of needs is here www.hollisterairshow.com/weneed.php
I'd really appreciate sone help with this, I've tried all combinations of double quotes, percent signs and nothing works...sigh.
TonyHere's the code that sets up the variable and prints it to the screen for test purposes
$saveNeedId = "-1";
if (isset($_GET['needId'])) {
$saveNeedId = $_GET['needId'];
print $saveNeedId;
Here's the code that sets up the hidden fields in the form, the one I'm trying to set up is the first one, needId
<input type="hidden" name="needId" value="<?php echo $row_rsNeedsUnmet['needId']; ?>" />
<input type="hidden" name="offerId" value="" />
<input type="hidden" name="MM_insert" value="form1" />
<input type="hidden" name="needId" value="<?php echo $_GET['needId']; ?>" />
I looked at your page. It looks like you figured it out. -
Start Routine to Populate Account Group Field from Master data of 0Customer
Hello Friends. Please help me edit this ABAP code to make it work. I am putting this code in start routine in between two DSO. where I am using the
Start Routine to Populate Account Group Field from Master data of 0Customer. I do not want to use read from master data functionality since that field 0customer is not there in dso but similar field 0debitor is there. so i want to put this code
during the load from source DSO to Target DSO.
Error Explicit length specifications are necessary with types C, P, X, N und
DATA: L_S_DP_LINE TYPE DATA_PACKAGE_sTRUCTURE.
types: begin of comp,
CUSTOMER type /BI0/OICUSTOMER,
ACCNT_GRP type /BI0/OIACCNT_GRP,
end of comp.
DATA: l_S_comp type comp.
DATA: L_th_COMP TYPE HASHED TABLE OF COMP WITH UNIQUE KEY customer INITIAL SIZE 0.
IF L_th_COMP[] IS INITIAL.
SELECT CUSTOMER ACCNT_GRP FROM /BI0/PCUSTOMER APPENDING CORRESPONDING FIELDS OF TABLE L_th_COMP.
ENDIF.
LOOP AT SOURCE_PACKAGE INTO L_S_DP_LINE.
READ TABLE L_TH_COMP INTO L_S_COMP WITH TABLE KEY CUSTOMER = L_s_DP_LINE-CUSTOMER
IF SY-SUBRC = 0.
L_S_DP_LINE-/BIC/ACCNT_GRP = L_S_COMP-/BIC/ACCNT_GRP.
MODIFY SOURCE_PACKAGE FROM L_S_DP_LINE.
ENDIF.
ENDLOOP.
soniya kapoor
Message was edited by:
soniya kapoorHello Wond Thanks for Good Answer and good option, But Client does not like this option and does not like Nav Attribute so he does not want to turn on any Nav Attribute, In general also We hav requirement to read a third table while uploading 1 dso table to 2 dso table,
so Please help me edit this ABAP code to make it work. I am putting this code in start routine in between two DSO. where I am using the
Start Routine to Populate Account Group Field from Master data of 0Customer.
No syntax Error But during the load it is updating the source table and not the target table. how to define now target table.
***SOURCE DSO Table
types: begin of typ_tgl1.
include type /BIC/AZDAFIAR000.
types: end of typ_tgl1.
types: begin of comp,
CUSTOMER type /BI0/OICUSTOMER,
ACCNT_GRP type /BI0/OIACCNT_GRP,
end of comp.
DATA: L_th_COMP TYPE HASHED TABLE OF COMP WITH UNIQUE KEY customer
INITIAL SIZE 0.
data: wa_itab type COMP.
data: wa_zdtg type typ_tgl1.
IF L_th_COMP[] IS INITIAL.
***Master Data Table
SELECT CUSTOMER ACCNT_GRP FROM /BI0/PCUSTOMER APPENDING CORRESPONDING
FIELDS OF TABLE L_th_COMP.
sort L_th_COMP by CUSTOMER.
ENDIF.
LOOP AT L_th_COMP into wa_itab.
select * from /BIC/AZDAFIAR000 into wa_zdtg
where DEBITOR eq wa_itab-CUSTOMER. *** SOURCE DSO Table
IF SY-SUBRC = 0.
wa_zdtg-ACCNT_GRP = wa_itab-ACCNT_GRP.
MODIFY /BIC/AZDAFIAR000 from wa_zdtg. *** modify SOURCE DSO Table
ENDIF.
endselect.
endloop.
soniya kapoor -
I have an Access 2013 Web App in my Sharepoint 2013 online website. It contains a query to report on its data (several, actually, but let's keep it simple). I want to connect an Excel spreadsheet to the query, visualise the data in pivot tables/graphs/whatever,
save the spreadsheet in a Document Library, and let other team site Sharepoint users open the spreadsheet (preferably in Excel online, but with Excel client if it has to be) and see/copy the data, refreshed with the latest information from the Access Web App.
Simple, surely!
The way I'm doing it at the moment is to create an ODC file to connect to the cloud-based Access 2013 database, save that ODC in a Data Connection Library in the SP site, and use the saved ODC file as data source in the Excel spreadsheet. This works and
successfully keeps everything 'in the cloud' but I can't get it to refresh in Excel Online, and if I open the spreadsheet in Excel Client I have to enter the database password every time to refresh it. I don't really want to issue this password to everyone
who might want to view the data. There must be a better way than this ODC method, I suspect.
Googlings on this have led down various blind alleys - Excel Services, PowerPivots, Web Parts - but I'm stuck on which to follow through. Please, someone, point me to an article/book/website that explains how to do this step-by-step in simple language..
thanks
JonathanI don't see any quick way of achieving it - at least there's no such functionality exists in SharePoint. All you can do, develop an event receiver that will update the fields in the list item once the excel file is added/updated. You can use OpenXml API
to manipulate the excel file.
Thanks,
Sohel Rana
http://ranaictiu-technicalblog.blogspot.com -
How can I access the Attribute Values from the Search Region
Hi all,
I have a table which contains Company id, department id, and PositonId. For a particular Company and Department there may be multiple records.
I have to pupulate a table which contains the position and other details that comes under a particular Department and Position based on the selection in the Three comboBoxes.
Also I have to populate a select many Shuttle to add new postions and records under a particular Department.
I created a query panel *(Search Region)* for the serch and a table to display the data. That is working fine.
Now the issue is I am using a view criteria to populate the shuttle with two bind variables ie, DepartmentId and CompanyId.
If the serach will return a resuktant set in the table it will also pupulate the correct records, otherwise ie, if the if the serch result is empty the corresponding iterator and the attribute is setting as null.
SO I want to access the attribute values from the Search Region itsef to populate the shuttle.
I don't know how can I access the data from the Search Region.
Please Help.
Regards,
Ranjithyou could access the parameters entered in search region by the user as follows:
You can get handle to the value entered by the user using queryListener method in af:query.
You can intercept the values entered as described
public void onQueryList(QueryEvent queryEvent) {
// The generated QueryListener replaced by this method
//#{bindings.ImplicitViewCriteriaQuery.processQuery}
QueryDescriptor qdes = queryEvent.getDescriptor();
//get the name of the QueryCriteria
System.out.println("NAME "+qdes.getName());
List<Criterion> searchList = qdes.getConjunctionCriterion().getCriterionList();
for ( Criterion c : searchList) {
if (c instanceof AttributeCriterion ) {
AttributeCriterion a = (AttributeCriterion) c;
a.getValues();
for ( Object o : a.getValues()){
System.out.println(o.toString());
//call default Query Event
invokeQueryEventMethodExpression("#{bindings.ImplicitViewCriteriaQuery.processQuery}",queryEvent);
public void onQueryTable(QueryEvent queryEvent) {
// The generated QueryListener replaced by this method
//#{bindings.ImplicitViewCriteriaQuery.processQuery}
QueryDescriptor qdes = queryEvent.getDescriptor();
//get the name of the QueryCriteria
System.out.println("NAME "+qdes.getName());
invokeQueryEventMethodExpression("#{bindings.ImplicitViewCriteriaQuery.processQuery}",queryEvent);
private void invokeQueryEventMethodExpression(String expression, QueryEvent queryEvent){
FacesContext fctx = FacesContext.getCurrentInstance();
ELContext elctx = fctx.getELContext();
ExpressionFactory efactory = fctx.getApplication().getExpressionFactory();
MethodExpression me = efactory.createMethodExpression(elctx,expression, Object.class, new Class[]{QueryEvent.class});
me.invoke(elctx, new Object[]{queryEvent});
Thanks,
Navaneeth -
Hi All,
I m new to CRM customization. I have requirement like this..
I have 3 entities.. Entity1 , Entity 2 and Entity3.
Entity1 is the parent of Entity2 and Entity3. Entity2 is the parent of Entity3 and child of Entity1 ..
In Entity1 I have a field eg:product1 which acts as lookup for Entity2 field availableproducts. Now in Entity2 I have a field the quantity of products which acts as lookup for Entity3 as given below.
In Entity3: fields:;; products==Lookup of Products(Entity1)
quantity == Lookup of Quantity (Entity2)
Now from Entity3 I need to update the fields of Entity1 like I have field named Price which is not visible on the Entity3 Form but when I access this field from javascript I m getting null exceptions since the field is not in the context of the Entity
on which it is defined. How can I update the fields of the Parent Entity1 from child Entity3 and also update the quantity field on Entity2 which are not avialable on the Entity3 Form.
Any help is appreciated
Waiting for the reply..
FayazSyedHi,
To do it in JS you need to use oData, as wrote above:
to make this requests easer, i use a XrmSvcToolkit library (https://xrmsvctoolkit.codeplex.com/)
Your code will be about this:
/// <reference path="rtb_XrmSvcToolkit.js" />
XrmSvcToolkit.retrieve({
entityName: "Entity1",
id: Xrm.Page.getAttribute("quantity").getValue()[0].id,
select: ["my_FieldNeedToUpdate"], //Here are the name of your fields, which you want to select.
expand: [""],
async: false,
successCallback: function (result) {
FieldNeedToUpdate= result.my_FieldNeedToUpdate;
errorCallback: function (error) {
Error = error;
FieldNeedToUpdate = FieldNeedToUpdate + 1; //Doing some work here
var InputEntity =
my_FieldNeedToUpdate: FieldNeedToUpdate //here are fields, witch you want to update
XrmSvcToolkit.updateRecord({
entityName: "Entity1",
id: Xrm.Page.getAttribute("quantity").getValue()[0].id,
entity: InputEntity ,
async: false
Here are more samples:
https://xrmsvctoolkit.codeplex.com/SourceControl/latest#Samples/XrvSvcToolkit.Samples.updateRecord.js -
How to populate the TEXT field in MIGO
Hi folks,
While creating material document in MIGO or MB01, i am inserting some data in TEXT ( Field in line item level ). This text data is disappearing , once mat doc is created.
how to populate the TEXT field in MIGO?Is there any cusomisation?it's urgent .
Regards
pabiHello Pabitra,
I had a similar issue in my Project.
Please verify if the SMOD enhancement MBCF0002 (EXIT_SAPMM07M_001) is active in your system.
If this is the case, verify from two angles:
a) Whether the Enhancement was accidentally activated - If yes, then De-activate the same
b) If there is some logic coded in the User Exit, but, the Text is somehow not determined...even the existing content in the text field (input to EXIT_SAPMM07M_001) will get vanished.
Hope that your problem will be resolved by this. Pls reward points.
With Regards
Vijay Gajavalli -
I would like the Treatment Classification field to populate with a combination of text and numbers based on my selection from three other drop down menus.
For example:
If I select "0-No Hurt" in the AHL field, "0-No Hurt in the PHL field, and "Near Miss in the Treatment Choice field, then the Treatment Classification field would populate to "L00NM".
If I select "2-Moderate Hurt: in the AHL, "4-Fatality" in the PHL field, and "Restricted Work Incident" in the Treatment Choice field, then the Treatment Classifiaction field would populate to "L24RWI".
If I select "1-Minor Hurt" in the AHL field, "4-Fatality" in the PHL field, and "Medical Treatment Incident" in the Treqatment Choice field, then the Treatment Classifiaction field would populate to "L14MTI".
Etc, etc, etc.
I could then fill in the resyt of the script with the required text.
Not sure how to load my PDF file.
Thanks,
RickDo your dropdown list items currently have export values set up? It seems like the value you want to construct is simply concatenating the values of the three dropdowns, and this would be easy if you set the export values of the list items appropriately. For example, the export value for the "0-No Hurt" item would be 0 and for "Near Miss" it would be "NM", etc., so the script could look something like:
// Get the values of the drop downs, as strings
var v1 = getField("AHL").valueAsString;
var v2 = getField("PHL").valueAsString;
var v3 = getField("Treatment Choices").valueAsString;
// Set this field's value
event.value = "L" + v1 + v2 + v3 + "other text goes here."
Maybe you are looking for
-
opening a new file in photoshop cc and the file name is displayed but no white working canvas. you can see it as a layer in the layers panel and if i draw on the grey area i can see int on the layer but not on the main screen.
-
My ipod touch is lost but i have the serial number how do i track it?
plz help
-
How can i extend the customer to other sales area
how can i extend the customer to other sales area
-
Can I unsync ipod without host computer?
Well can I? Also how do I set up my mutiple ipods to work with my multiple computers? Thanks Travis
-
Adobe PDF pack cannot download
I ordered and received acceptacne but not a confirmation email for Adobe PDF pack, so cannot download PDFs now.