2014년 12월 12일 금요일

barcodescanner question

I'm trying to create an app that scans a qr code and plays a video from a local source on the device. i keep getting an error that it cannot play the video and it puts an http before the qr code text

please help if you can. 



It would really help if you provided a screenshot of your relevant blocks, so we can see what you are trying to do, and where the problem may be.



I was trying to make it super simple, press a button and depending on what qr code it scans it automatically plays a video.




Have you checked the result in the BarcodeScanner1.AfterScan to see what you're getting back?  Use DoIt there and find out what info the result is holding.  Read the tips below too...




Yeah for some reason when I put the .mp4 at the end of a qr code it adds https:// to the front. Is there a left trim command?



It's up to you to get that result, and format it in the way the player needs...  Trim won't do it as it would be on the right and empty spaces.  You'll have to look through the string parsing what you need with the split and other blocks from the text drawer...



If I redefine the result variable as 1.mp4 after its read by the scanner it works fine. If I put in the qr code just "hello world" that is the exact text that comes out. How come when I put in 1.mp4 into the qr code I gethttp://1.mp4?



well I've figured it out.
that set lable block was used just as a debugging tool. basically for some reason when the barcode scanner reads in a .___ it assusmes its a website and puts the http at the front so i just added in the .mp4 after it read the code. 


댓글 없음:

댓글 쓰기