I am working on this project. The user will need to scan in two barcodes. The first barcode will initiate a lookup to populate a few fields in the report, and the second barcode is simply populated to the report.
My problem is both barcodes have leading zeros in them and if I included the zeros in the report, there would not be enough space on the report.
The first barcode consists of the following possibilities: 1. pure numbers with leading zeros 2. alpha-numeric combo without any leading zeros
The second barcode always has 5 leading zeros with it.
Anyone knows how I can only show the information on the report without any leading zeros?
Thanks in advance
The first barcode you should leave, text as it is.
The second, if numeric, you can strip for leading zeroes this way:
StrippedBarcode = CStr(Val(ScannedBarcode))
Related
I have a SQL query outputting a column which contains data from emails and chart conversations with lot of spaces, special characters, how can I clean and make this data show up in one row so that I could save the table output into a CSV file.
PS: the query output is in millions.
This could help. Instead of the space character use just empty quotes as the third parameter.
I have list of amounts, which are without decimal dash, but I need to add it before 2 digits from right. Here is the example of data:
So, basically, I would need to add dash / dot like that:
-1297.25
-5517.92
-4653.97
etc.
I dont know, how to treat it, since the number of digits from left side will change from case to case, therefore I cant use =REPLACE function.
Could you advise me, please?
Many thanks!
The screen shot insinuates that the cells really store Cent values ... if this is the case then make a temporary column where you use a formula =[Cell]/100 to convert to EUR with Cents in decimal place... then copy/paste values back the results and format accordingly.
If you don't want to use a formula, search for a free cell and write a 100 in it. Copy this cell to the clipboard. Select the area you want to edit, right-click on it and select "Insert content...". In the following dialog, simply select Divide and press OK. And that's it.
I need to display discount % up to two places of decimal in a SSRS report. The current expression that i am using is "Fields!Discount.Value" and its generating inconsistent values in the report.
In the top designer bar in the number field, change it from Default to Number. Then use the little decimal buttons to adjust how many decimals you will allow to be shown.
I don't have enough rep to post images, but screen shot link below.
Screen Shot
I have a requirement where I need to display account number in RDLC such that it displays last 3 characters and all other characters are displayed as '*'. for eg 1234567 needs to be displayed as ****567. I'm passing in dataset containing account number to the RDLC and need to write an expression which will format account number to display 3 last digits and all preceding characters as"*". Can anyone help me with the expression writing for it? I'm very new to writing expression on RDLC.
I figured it out.... I wrote code to format account no with asterisks and called the method in RDLC expression.
I have a SQL Server view I'm pulling into an excel macro workbook. However, one of the date fields is being treated as a number by excel and it's leading 0 is subsequently being stripped off. Is there a datatype I can convert my date field to in SQL so that excel does not strip off it's leading zero when the view is imported into the workbook?
How are you pulling the data in? AFAIK there's no Excel-wide setting to keep the leading zeros, however there are ways to keep them, or to add them back:
From Microsoft
If you're using the import wizard,
Convert the number to text when you import text data
In Step 3 of the Text Import Wizard (On the Data tab, in the Get
External Data group, click From Text), you can select the column of
data that contains the credit card number, and then explicitly choose
a Text column data format.
Alternatively, if you already imported the data and there's a pattern/structure to it, you can create a custom format:
Use a custom format to keep the leading zeros
If you want to resolve the issue just within the workbook because it's
not used by other programs as a data source, you can use a custom or a
special format to keep the leading zeros. This works for number codes
that contain fewer than 16 digits,
In addition, you can separate some of the digits in your number codes
with dashes by adding these dashes to the custom format. For example,
to make a phone number more readable, you can add a dash between the
international code, the country/region code, the area code, the
prefix, and the last few numbers.
Edit: I'm not to keen on SQL, so can only offer more Excel focused ideas :/