Friday, January 10, 2014

Kindle USB issue - Cannot connect Kindle to PC

My kindle 3 (keyboard) was not connecting to my PC, but it did connect to any other PC.

I tried everything I found on the internet:
- restart from kindle button
- restart from Kindle settings
- checked all the USB ports in fromt (2 of them) and in the back (6 of them)

nothing worked

when i plug it in, the PC displays the Safely Remove Hardver icon in the tray, and the Kindle goes to that "USB drive mode" screen. No Kindle drive. If I "safely remove" then it still charges, the "USB drive mode" screen goes away, i can check my books, but still no kindle drive

What did I do?

I went to Device Manager, Kindle was visible (charging worked), and on Properties, I was browsing through the tabs. On the 3rd tab ("Volume") I had a Populate button, I clicked it. It showed me Kindle(E)

BUT

my E drive was a network connection (Network share), a kind of shortcut to an other computer from the LAN

i disconnected my "old" E drive, the Network Share.

Ta Da !

All the Kindle folders suddenly showed up on the E drive right there.
Case closed.

Seems like the Kindle was trying to force itself to a (taken) drive letter, not sure why.

If you ever have the same issue, if you don't see the Kindle drive in Windows File Explorer, try if you can see it in (My Computer - Manage) Computer Management - Disk Management, maybe all you need to reallocate some drive letters.

Wednesday, October 9, 2013

CONVERT DATETIME seems all right, but still ...

A table with a varchar column that has date and other value types too.
A query with a simple CONVERT DATETIME

Conversion failed when converting date and/or time from character string.
Crashing. Over and over again. I start to call it X-Files.
Until I read THIS.

Not only I know why it happened (and sortof feel like SQL is "stupid" :D) but I get an interesting idea to work around the issue.

Thursday, September 26, 2013

F7 - Visual Studio - switch between aspx and "codebehind"


It was not working for me.
This is what I had to do:
  • Bring up customization dialog with "Tools\Customize..."
  • Bring up the keystroke mapper with "Keyboard..."
  • Set focus in "Press Shortcut Keys" text box
  • Press F7 or some other keystroke you want
  • The "Shortcut currently used by" box will show the command currently invoked by the keystroke.
  • Set focus to "Show Commands Containing" and type ToggleDesigner
  • This will select the View.ToggleDesigner command in the list box of commands
  • Next press the "Assign" button to assign the keystroke shortcut to the command.
  • Click "OK" to the keystroke mapper dialog
  • Click "Close" to the customization dialog

Thursday, June 27, 2013

SQL split using Parsename

Interesting way to SPLIT stuff in SQL

Parsename, read all about it, here
DECLARE @FullName VARCHAR(100)
SET @FullName = 'John Doe'

SELECT PARSENAME(REPLACE(@FullName, ' ', '.'), 2) AS [FirstName],
PARSENAME(REPLACE(@FullName, ' ', '.'), 1) AS [LastName]

Thursday, March 21, 2013

TextboxWatermarkExtender and Textbox with TextMode = Password


I managed to do this by setting the watermark stylesheet to overlay an image in the textbox.
You simply take a snapshot of how you want the watermarked textbox to look, save that, then set the watermark css of that textbox to a style that displays the image and aligns the text to the right (because otherwise it will still be visible)
It's very easy and works flawlessly.
The Textbox:
<asp:TextBox ID="Password" runat="server" CssClass="txtbox_login" Width="120px" TextMode="Password">

The Watermark (Set the WatermarkText property to anything you want, but just one character):
<ajax:TextBoxWatermarkExtender ID="txtWMark2" runat="server" WatermarkCssClass="watermarked_psw"TargetControlID="Password" WatermarkText="*" />

The StyleSheet (You MUST align the text to the right, otherwise it will still display over the image):
.watermarked_psw
{
colorWhite;
font-familyTahoma;
font-size11px;
bordersolid 1px #a9a9a9;
text-indent:2px;
vertical-align:middle;
text-align:right;
background-image:url(../images/psw_wMark.png);
background-repeat:no-repeat;
}

I found this one here, by JeanT
It works !

Friday, February 15, 2013

SQL for CNP :D

create table #cucu(bau varchar(10)) insert into #cucu (bau) values ('123') insert into #cucu (bau) values ('3888') insert into #cucu (bau) values ('2888') insert into #cucu (bau) values ('6888') insert into #cucu (bau) values ('300a') select * from #cucu where bau LIKE '[3,4,6][0-9][0-9][0-9]' drop table #cucu

Tuesday, March 13, 2012

Samsung Galaxy S2 connection problems

Samsung Galaxy S2 connection problems

Samsung Galaxy S2 connection problem

I recently wanted to connect my Samsung Galaxy S2 to a PC.

1. My first problem was because of the device has not been recognized.
USB device not recognized windows error messsage.

To fix this:

Settings > Applications > Development > USB debugging checkbox - I checked it

Then it connected.

2. The second error was right after that. Error message:

"Reconnect the device in samsung kies mode"

Well, believe it or not, I had to do it bacwords

Settings > Applications > Development > USB debugging checkbox - I UNchecked it

and it worked

[UPDATE] I tried it again, and found out that I have to have the the phone unlocked too
(I use that unlock-pattern-draw-feature)

This all after long hours of reading forums ... and stuff

Hope it helps, comment if it did ;)

cheers