You need to sign in to do that
Don't have an account?

add text field
how to add a column to my table on a text field the user will fill the text field isnt bounded to any object and i want to transfer its data to controller
You need to sign in to do that
Don't have an account?
If thats the case, you need to create a wrapper class, which will be a class containing an object and then custom parameters with it like a boolean field for selecting it or text field for data input. Here is a great reference and example regarding wrapper classes:
http://wiki.developerforce.com/page/Wrapper_Class
usually inputField is used to map to an object field thats stored in salesforce and inputText is used to map to a controller variable which is not persisted in an object..
check this link for more details on apex:inputText
https://www.salesforce.com/us/developer/docs/pages/Content/pages_compref_inputText.htm
please check below code if this code help full for you..
<apex:page standardController="Employe_bisp__c" sidebar="false">
<apex:form >
<apex:pageblock >
<apex:dataTable value="{!Employe_bisp__c}" var="emp1" border="2">
<apex:column >
<apex:facet name="header">Name</apex:facet>
<apex:inputField value="{!emp1.name}" id="a1"/>
</apex:column>
<apex:column >
<apex:facet name="header">Employee Salary</apex:facet>
<apex:inputField value="{!emp1.Salary__c}" id="a2"/>
</apex:column>
<apex:column >
<apex:commandButton action="{!save}" value="Save"/>
</apex:column>
</apex:dataTable>
</apex:pageblock>
</apex:form>
</apex:page>
thanks..