last day (14 days later) » 

7:25 AM
hi
 
Hi...
I'll tell u what i need exactly and what i am doing
 
okay
 
My main tableview's code
 
where are you from? India?
 
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
if (indexPath.row==1)
{
static NSString *simpleTableIdentifier = @"SimpleTableItem12";

for (int i = 0; i <= resCommentsArray.count; i++)
{
NSIndexSet *indices = [resCommentsArray indexesOfObjectsPassingTest:^(id obj, NSUInteger idx, BOOL *stop) {

if (!([arrPostId count] <= indexPath.section))
{
return [[obj objectForKey:@"user_sell_post_id"] isEqualToString:[NSString stringWithFormat:@"%@",[arrPostId objectAtIndex:indexPath.section]]];
Tableviewcell is a custom tableviewcell
yes...
 
7:28 AM
ok see I will tell you the basic idea how to do...
okay?
basic idea batata hu
chalega?
 
hann bhai sure...
 
you need to do calculation in heightForRowAtIndexPath
 
lekin height mujhe customtableviewcell ki karni he
me uska code deta hu wait.
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{

static NSString *CellIdentifier = @"cell";
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];

if (cell == nil)
{
cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault
reuseIdentifier:CellIdentifier];
}


self.tbl.backgroundColor = [UIColor greenColor];

UIButton *btnUserName = [[UIButton alloc]initWithFrame:CGRectMake(20, 0, 50, 20)];
- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath
{
NSString *str = [arrComments objectAtIndex:indexPath.row];
// NSLog(@"%@",str);


CGSize size = [str sizeWithFont:[UIFont fontWithName:@"Helvetica" size:14] constrainedToSize:CGSizeMake(280, 999) lineBreakMode:NSLineBreakByWordWrapping];
NSLog(@"%f",size.height);
if (size.height<20)
{
size.height=20;
//m= size.height;
}

return size.height + 30;

}
aur yahhn pe jo height milti he wo mujhe main view pe heightforrow me deni he
 
give me 5 mins
i m preparing text for you
 
ya sure man
ohhh thanks...
 
7:33 AM
// now let's say you want to show the text in cell and you don't know what height can be... in this scenario below is what I do..
// this is considering I am using full row to display the text... 320 will change as per your text display...
UILabel *dummyLabel = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, 320, 10)];

// we assigned the text here
dummyLabel.text = [[yourArray objectAtIndex:indexPath.row] valueForKey:@"textVariable"];

// now set font // this is same font you are going to use in actual cell...
this is basic idea
agar nahi samja to bata dena... i will tell u
all this code will sit in heightForRowAtIndexPath
bhai kidhar kho gaye?
 
aree my manager called me up so...
sorry
haan sahi he bhai...
@FahimParkar:
tweetLabel = [[STTweetLabel alloc] initWithFrame:CGRectMake(20,27,itemTextSize.width+10, textHeight-2)];

tweetLabel.text = [arrComments objectAtIndex:indexPath.row];
tweetLabel.font = [UIFont systemFontOfSize: 12];
i have already passed it lik this...
how to pass this dynamic height on height for row???
Ab aap kho gaye bhai???
 
7:52 AM
hehe
see my code
 
Yeah i saw that and tried but my error is quite confusing too u i guess.
wait...
0
Q: Increase the main tableview row height according to the custom cell

Maulik ShahI am having an app in which I have a Tableview and on that tableview's each row I am dynamically creating a custom tableview cell. Below is the code for that. NSArray *nib = [[NSBundle mainBundle] loadNibNamed:@"flowviewTableViewCell" owner:self options:nil]; cell2 = [nib objectAtIndex:0]; re...

This is what i want exactly...
 
I give u basic idea
 
ok just let me know that...
 
u got what I am doing?
 
yes exactly
with your code i got it but how to pass that height on another view's heightforrow method?
 
8:00 AM
not sure...
i need to be there to solve..
aise mujhe nahi samajh me aayega
sorry...
 
aahh ok!!!
I can understand!!!
If u r ok thn i can give u the code.
I have put the que for you and if u r free den u can help me on that one.
I'll be availabe after 1.5 hours caz f a meeting...
sorry... Will ping u wen i come...
 
 
2 hours later…
9:39 AM
i will go from this room...
 
@FahimParkar:Hi...
Are u der?
 
10:13 AM
@FahimParkar:Kya bhai busy the to bol diya hota!!!1
 

last day (14 days later) »