Formatting Numbers
Oct 25, 2006
Hi all,
I am trying to format three fields to write to a table.
For reasons unknow they are created as text so I tried using Cint, Clng and cdbl to export thee fields as numbers so when they are exported to an excel spreadsheet they are as number fields.
This actually works for exactly that but the end result knocks off the leading zero if the value is 0910 it ends up as 910. The source table it pulls this from actually has the leading zero if the length is less then 2.
How do I get to format the fields to numbers but keep the exact value ?
Any help is greatly appreciated.
Mitch.....
View Replies
ADVERTISEMENT
Mar 24, 2008
My database is a maintenance record of our building complex. The unit/building number is the key field. The problem I am having is having access recognizing the unit numbers and building numbers, not as whole numbers.
Example: I-380, 10-380, 2-390, 13-370, and so on. When sorted, access treats them as whole numbers. I have tried two separate fields but it would be nice to have only one field and be sorted by building numbers.
I am not a coder so be gentle.
Can you help?
View 9 Replies
View Related
Apr 19, 2011
I try to modify an access 2010 template from the MS website.The problem is that the template as is programmed does not accept as input negative prices. I need to use negative prices for offering discounts on my invoices. In my country the discounts are only displayed as products with negative prices/values. We do not use % discounts.
i try to create an products with negative price and to use it as an discount on the invoice. Both the products input form and the invoice input form give me the same error : "please specify an price list that is not negative" or "please specify non zero positive prices" ( sometimes it allow me to enter but when the software try to validate the form/invoice i just entered it give me those error/messages)
I changed all the field from currency in general numbers Where do I have to change in order to remove those formatting/condition..? The template has a lot of macros.. I an not able to change those macros if there are some formatting conditions in them. If it is allowed I will post the link to the free template i use to be more conclusive..Or I can give/ upload the template I use.
the link to my data base ( dropbox)
View 3 Replies
View Related
Oct 23, 2014
How can I format the output of subtracting two times as a time value. For instance 10:00 am - 9:00 AM = 1 (where I want to show the output as "1").
View 7 Replies
View Related
Apr 24, 2014
I have an INSERT query like so:
Code:
INSERT INTO table1 (column1, column2, column3, column4, column5)
SELECT (field1, field2, field3, field4, field1 & "" && field2)
FROM mastertable
According to the format desired by a client, column5 from table1 needs to have field1 and field2 concatenated and represented as two-digit numbers if they're a one digit (has a leading zero).
View 7 Replies
View Related
Nov 26, 2013
I want to print the results of a query where some values are whole numbers, some have 1 decimal place, some have 0.3333333 recurring etc. Problem is that in order to fit all the columns on a page the column width does not allow all the 0.33333... to display. So what I see is like this (there are lots of columns, I am just giving an example from one column)
891
833.5
######
I don't want to fix decimal places to 1 because then I would see 891.0 instead of 891. How can I format the number field so that whole numbers are shown without decimal place, numbers with 1 decimal place stay like that i.e. 833.5 is fine as it is. But display something like 313.666666666667 as 313.67 rather than ##### getting put in as not enough room for all the decimal numbers.
View 5 Replies
View Related
Oct 6, 2014
I am using VBA to execute a 'Make Table' (named 'DT'). One of the fields in DT (named 'Dollars') contains numbers that have 6 to 8 digits; some are positive and some are negative.
These large numbers with no commas (or parentheses when they're negative) are incredibly hard to read.
Any VBA coding that will change both the "Format" and the "Decimal Place" Field Properties on the table I make (i.e. "DT"). I want to the Format property to read (#,##0.00;(#,##0.00)) and the Decimal Place property to read "2"). This will allow me to display a number like -10326786.41 as (10,326,786.41) which is incredibly more readable.
Is it possible to do this programmatically; I've search the internet high and low and could find anything remotely useful.
View 8 Replies
View Related
Aug 1, 2014
Need to confirm whether the Default formatting option in the Conditional formatting Dialog won't work in datasheet view of a form. Please note that all conditional criteria are working fine but not the Default Formatting option - only in the Datasheet view (In Single Form view the default formatting is working fine)
View 11 Replies
View Related
Aug 12, 2014
I'm having multiple problems with my database like things such as -
i'm currently working on the Query 2 - On the Phone database (ignore Query 1) and i want to search for multiple plot numbers preferably in one parameter prompt with a comma to seperate numbers. (this could be a multitude of numbers so i would like to be able to input as many as needed). Also when i do search on this query since the Criteria is a 'Between' Value i would expect everything between the 2 numbers input to show up - but a lot of numbers out of the range show up too - why is this? (The Numbers are like "69 to 136" and they will show up - but 1-69 and 136-170 would too
I would also like to implement the search results from Query 2 into the Form i currently have made but it just opens up a access table when the search is made?
i cannot link my database as it is too big for the server - But here are the Criteria for Query 2:
Plot No - (criteria = Between [Enter First Plot No:] And [Enter Last Plot No:])
Site - (criteria = Like "*" & [Enter Site:] & "*")
Product - (criteria = Like "*" & [Enter Product:] & "*"
The Query is the one im most concerned about , i can live without a form.
View 14 Replies
View Related
Jan 10, 2007
Ok so in excel I have some numbers that are stored as text. The reason being that they are zip codes and some begin with 0 and excel doesn't want numbers to start with 0....so when I import these into an access field that has an input mask for zip codes...will it convert these correctly since the field is a text with input mask?
View 1 Replies
View Related
Aug 24, 2014
I have 2 fields that I would like to automate if possible
One field is called "p/o number" and another field called "line no"
These fields are part of an ordering database
Let say I have 200 items to purchase form 10 suppliers
And form example 20 items from each supplier
What I do at present is put the order number on each line item and the line number
example
p/o number line no
1 1
1 2
1 3
2 1
2 2
2 3
2 4
What I want to do is just put the first po number in the required line . Put the first line number in i.e. "1" and the macro will complete all the p/o numbers and line numbers for me as per the ones marked in red.
Example
1 1
2 2
3 3
2 1
2 2
2 3
View 5 Replies
View Related
Oct 28, 2014
I have a table with fields like this one but the weeks go all the way up to 52. What I am trying to do is count the number of consecutive zeros and if it is more than five, count how many of the following fields have a number in them and if that number is less than the number of zeros preceding it identify that person.
For example Joe would be identified below because he had 6 consecutive zeros and then he had 5 weeks of numbers immediately following the string of zeros. Bob would not be identified because he had 5 consecutive zeros and then 5 sets of numbers immediately following the string of zeros so the zero frequency isnt higher than the number frequency immediately following.
ID
Name
Date of Hire
1
2
3
4
5
[code]...
View 5 Replies
View Related
Apr 13, 2006
Really simple one for all you folks out there, but I've just been struggling for 20minutes and thats it I've decided to to seek proffesional advice. Though its been said I need it in other areas of my life too (so my ex says but..), any way I digress.
I put a tab control on a form all I want to do is format the title of each individual Tab name, i.e. font size etc, type. Had a look at the properties but nothing there seems to register.
Is it possible?
View 6 Replies
View Related
Apr 20, 2006
Hey do any of you guys know if its possible to change the colour of the tabs or set them as transparent in a form plz??? I know you can set the background as transparent, but i dnt know if you can do that to the actual tabs.
Thanks guys
Zaf
View 1 Replies
View Related
Jul 20, 2005
Ok, don't know what I should title this problem as, but maybe you guys can help. The data stored on my table is formatted as Currency, however, when I Queue up the data, I also multiply it by a factor (exchange rate). Which turns the data into just a regular number. When I display this data on my form, I reformat it into Currencies again. However, when I click on the field, it shows the number in its raw format. How can I fix this so that when the user click on the field, they won't see the raw number but just regular Currency format? Much thanks in advance.
View 9 Replies
View Related
Feb 5, 2007
Hi,
I am creating a database of private equity funds. I want to have a currency field for an input entitled fund size. However, I need to be able to display whether the size of the fund is in dollars or euros. How can customize a number/currency field to allow me to input the correct currency symbol?
Thanks
View 2 Replies
View Related
Nov 8, 2006
Hi
I have a database with multiple tables all linked together in various ways. I would like a master reset button that will delete every record in every table as well as resetting the auto number(s) back down to zero again. Can this be done and if so, how?
Thanks in advance.
Dave
View 9 Replies
View Related
Mar 11, 2007
I'm trying to format a header in a report and need some help.
The following results in "Error" if placed as the Control Source :
=IIf(IsNull([Captain]),"","Captain:" & [Captain])
Is there another way to do this?
Essentially, I want to display the word "Captain: " followed by the name if there is an entry. If there is no captain, I want to display nothing.
Thanks for the help!
View 1 Replies
View Related
Aug 24, 2007
In my report the data shows patients and which unit they are in so in the detail section it shows something like this depending on how many records there are:
CVICU
CVICU
CVICU
MSICU
MSICU
NICU
STICU
STICU
STICU
I'm now modifying that report to show totals and I want to list the names of the units going across the page not down the page which shows all the records. I moved the field into a "Unit Footer" and now the report shows only one entry for each unit like this:
CVICU
MSICU
NICU
STICU
Within the Unit footer section I don't want the names of the units going down but across like this:
CVICU MSICU NICU STICU
I know there must be an easy answer but I've looked and work on it for so long I can't see what it would be. Any help would be GREATLY appreciated.
Thanks so much in advance.
View 3 Replies
View Related
Apr 20, 2006
Hi,
Please see attachment. I have created a mini database which will hopefully help me in explaining the process.
Table1: Field1 - 8 rows/8 records
Form1: Field1 text box
So in this box I used conditional formatting to say- whenever the date is greater than 04/05/2006, turn red.
So now I scroll to record2, need to have new conditional formatting rules to apply to this record.
My understanding is that I can use the remaining 2 conditions for records 2 and 3.
But what about records 4,5,6 & 7.
For example in record 4 I need the date to be greater than 02/15/2006, and record 8 to be greater than 05/09/2006-and as you can see when you scroll down to record 8 it has already turned red because it is governed by the rules in record1!
Hopefully this makes sense!
Is there a way to get around this? Is conditional formatting the only way to achieve this?
If it's not what would I do?
Thanks in advance for your help!
Jcwishart
View 1 Replies
View Related
Sep 7, 2005
I am having trouble formatting a mailing label zipcode using the xxxxx-xxxx format.
I am using the =Trim([City]&","&[State]&" "&Format([ZipCode],"@@@@@-@@@@")) for Access 2002
My program is Access 1997-is there a different formula and why isn't the above working?
The zipcodes that have an extension come out right but the ones that don't have an extension come out like 6-8894
Any help would be appreciated!
View 3 Replies
View Related
Dec 15, 2005
Hey everyone, I need some help with formatting a string for use with the DoCmd.RunSQL() method. I can't figure out how the hell VB deals with escape characters for the purpse of variables inside strings. I have this line right now.
strSQL = "INSERT INTO OS (OS) VALUES(" + OS.Value + ")"
This is supposed to insert one row into the "OS" Table, in the "OS" field. In my form there is a textbox called "OS" and I'm trying to insert that value into the DB table.
Two things.
1) Yes, I know, I have a lot of things named "OS"
2) Yes, I know I don't need to use a string here, but I'm just presenting this is an abbreviated example, in my full program I do in fact need a string.
View 3 Replies
View Related
Mar 7, 2006
hi all, first time poster, with an awkward question.
i'll save you my life story but suffice to say i'm just 3 weeks into a 6mnt work placement from college and i could do with a bit of help.
the company i'm working with has to generate an xml document (preferably with access) corresponding to this schema (http://www.ros.ie/schemas/eusavings/v1/schema.xsd)
the problem so far as i can make out is that when i import this xsd into ms access - i'm presented with a rediculous number of tables and in turn these are not related, i.e. there is nothing to say that the e-mail address table is associated with the header table. (having them in one table makes more sense to me, but i'm not an expert, all i know is i have to comply with this xsd.)
when the data is exported to xml format, it's meant to look like this:
<?xml version="1.0" encoding="UTF-8"?>
<EUSavings formversion="1" periodstart="01/07/2005" periodend="31/12/2005" language="E">
<HeaderDetails>
<PayingAgent>
<TaxNumber taxtype="4">1234567T</TaxNumber>
<PayingAgentName>
<NameDetails>Joe Bloggs</NameDetails>
</PayingAgentName>
<PayingAgentAddress>
<AddressLineDetails Type="Line1">Test Road</AddressLineDetails>
<AddressLineDetails Type="Line2">Test City</AddressLineDetails>
</PayingAgentAddress>
<PayingAgentCountryCode>
<CountryCode>IE</CountryCode>
</PayingAgentCountryCode>
</PayingAgent>
<FileSequenceNumber>1</FileSequenceNumber>
<PaymentYear>2006</PaymentYear>
<ContactDetails>
<ContactName>
<NameDetails>Paul O'Neill</NameDetails>
</ContactName>
<TeleNumber>
<TeleNumberDetails>0875252252</TeleNumberDetails>
</TeleNumber>
<EmailAddress>
<EmailAddressDetails>test@test.com</EmailAddressDetails>
</EmailAddress>
</ContactDetails>
</HeaderDetails>
<AccountDetails>
<DocumentType>1</DocumentType>
<AccountHolderDetails>
<FormType>A</FormType>
<KeyName>
<NameDetails>Jones</NameDetails>
</KeyName>
<OtherNames>
<NameDetails>Tom Paul</NameDetails>
</OtherNames>
<Address>
<AddressLineDetails>New Road</AddressLineDetails>
<AddressLineDetails>New City</AddressLineDetails>
</Address>
<AddressCountryCode>
<CountryCode>GB</CountryCode>
</AddressCountryCode>
<BeneficialOwnerResidenceCountryCode>
<CountryCode>FR</CountryCode>
</BeneficialOwnerResidenceCountryCode>
<BeneficialOwnerBirthDetails>
<DateOfBirth>01/01/1945</DateOfBirth>
<BirthCity>Paris</BirthCity>
<BirthCountryCode>
<CountryCode>FR</CountryCode>
</BirthCountryCode>
</BeneficialOwnerBirthDetails>
<PaymentType>0001</PaymentType>
<CurrencyCode>EUR</CurrencyCode>
<AmountPaid>8889</AmountPaid>
<AccountIdentifier>152525525</AccountIdentifier>
</AccountHolderDetails>
<ReferenceNumber>455200211</ReferenceNumber>
</AccountDetails>
</EUSavings>
everyone in this company is completely new to xml and seeing as i have a little experience with it from college i've got quite a bit of pressure on me to try and make this work.
so, my question is: how would i go about exporting data from access into a xml document which conforms to the xtd, and looks like the xml code above?
is access capable of doing this?
they want this solved programatically, but nobody here knows how to do it.
can anyone offer guidelines on how to tackle this? any help would be really appreciated, i'm in over my head
View 3 Replies
View Related
Apr 18, 2006
Hi Guys,
I've a question and I hope you can help me out.......
I'm trying to use Conditional Formatting Options on a Text box called "Date". I'd like that this box become Red if its value is between value1 from Text box "Start Date" and value2 from Text box "End Date" or Green otherwise (in this way the color change dynamically every time I change the values of Text Boxes "Start Date " and "End Date"). How can I do that? What I need to type in the Conditional Formatting Windows?
Thanks a lot for you help!!!!
Ciao Ciao
View 1 Replies
View Related
May 31, 2006
I wondered if someone could point me in the right direction.
I am pulling dates from a table in the format:
7092000
11092000
How can I reformat to:
07/09/2000
11/09/2000
Thanks
Paul
View 10 Replies
View Related
Jun 28, 2007
I'm having an issue with the way my number fields are displayed on my form.
I want the number to be dislayed with 2 decimal places. I have formatted the numbers so that they are 'fixed' and specified 2 in the decimal places property but my numbers are rounding themselves down.
eg. I type 1.25 but it comes up as 1.00
Thank you in advance for your help.
View 3 Replies
View Related